What is the stochastic oscillator?
The stochastic oscillator measures where the close sits inside the high-low range of recent bars, on a 0 to 100 scale.
A close at the top of the 14-bar range scores 100, at the bottom 0. Ours is the slow version: the raw reading is smoothed by a 3-bar SMA to give %K, and %D is a further 3-bar SMA of %K. When the range is zero (every bar identical) the raw value is set to 50. Dashed guide lines sit at 80 and 20 and can be moved in settings.
How is the stochastic oscillator calculated?
raw = 100 × (close - LL) / (HH - LL) over 14 bars, %K = SMA(raw, 3), %D = SMA(%K, 3)
The terms in the formula
- HH, LL
- highest high and lowest low of the last 14 bars
- %K
- the smoothed main line
- %D
- the signal line, an average of %K
How do you read the stochastic oscillator?
- Above 80 the close keeps finishing near the top of its range, often called overbought; below 20 near the bottom, often called oversold.
- %K crossing above %D is read as momentum turning up, crossing below as turning down; crossings inside the extreme zones get the most attention.
- A move through 50 shows the close shifting from the lower to the upper half of the range.
- Divergence, where price makes a new high but the stochastic does not, is often read as fading momentum.
What are the limits of the stochastic oscillator?
- In a strong trend it can stay above 80 or below 20 for weeks; an extreme reading alone says little about a reversal.
- In choppy markets %K and %D cross constantly and most crossings lead nowhere.
- It ignores volume and the size of the range: a 1% range and a 10% range can give the same reading.
- Gaps and one-off news bars stretch the 14-bar range and distort readings until they roll out of the window.
Where can you see it on TickerBase?
Open a live chart and add the indicator