Tool
Stochastic RSI
market.stoch_rsi
Inputs
No typed inputs.
Outputs
A 0–1 momentum line built on top of RSI; above 0.8 is overbought, below 0.2 oversold. It swings to the extremes more often than plain RSI.
Stochastic RSI (Stoch-RSI) is a momentum oscillator that applies the Stochastic formula to RSI values instead of to price. It reacts faster than plain RSI and reads on a 0–1 scale, where roughly above 0.8 is overbought and below 0.2 is oversold.
How it works
First RSI is computed over rsi_period bars. Then, over stoch_period bars, it measures where the current RSI sits between its own recent high and low: 1 means RSI is at the top of its range, 0 means the bottom. Because it stretches RSI across its range, it swings to the extremes more often than RSI itself.
Modes
Build the underlying RSI from each bar's open price.
When to use: Use open when the bar's opening price best reflects the move you trade.
Build the underlying RSI from each bar's high price.
When to use: Use high when the bar's high best reflects the move you trade.
Build the underlying RSI from each bar's low price.
When to use: Use low when the bar's low best reflects the move you trade.
Build the underlying RSI from each bar's close price (the usual choice).
When to use: Use close for the standard Stoch-RSI most traders expect.
Build the underlying RSI from the bar's median price, the average of high and low.
When to use: Use HL2 to smooth out where open and close fell and focus on the bar's range center.
Build the underlying RSI from the typical price, the average of high, low and close.
When to use: Use HLC3 when you want the close to count but still blend in the bar's range.
Build the underlying RSI from the average price, the mean of open, high, low and close.
When to use: Use OHLC4 for the smoothest input, weighting the whole bar equally.
Configuration
How many bars the underlying RSI averages over before it is stretched. Larger = smoother and slower; smaller = faster and noisier. 14 is the classic default.
How many bars of RSI history the Stochastic looks back over to find the recent high and low. Smaller makes the oscillator hit 0 and 1 more often.
Which price each bar contributes to the underlying RSI (close is the usual choice).
Connects to
Examples
- Filter: take a long only when Stoch-RSI turns up from below 0.2 inside an uptrend.
- Cross Stoch-RSI with the 0.5 midline to read short-term momentum direction.
Common mistakes
- Treating every push above 0.8 or below 0.2 as a reversal — in a strong trend it can pin at an extreme for many bars.
- Forgetting it is twice-smoothed: with both periods short it becomes very whippy and gives frequent false signals.