Skip to main content
Track Price-indicator divergence
4 / 16
Library

1990issue C121-2

Constructing stochastic K and D lines and divergence cues

A stochastic oscillator places the latest close between the lowest low and highest high of a chosen lookback and scales that placement from 0 to 100. This article assembles raw percent K from a five-bar high-low window, derives percent D as a three-bar smoothed companion, and keeps the zone-and-cross cue and price-indicator divergence as two constructions on the same sampling interval.

  • A stochastic oscillator is a 0-to-100 reading that locates the latest close inside a chosen window of the highest high and lowest low.
  • Raw percent K uses a five-bar lookback. Percent D is the three-bar smoothed companion formed from summed close-to-low distances over summed high-to-low ranges.
  • A zone-and-cross cue counts a percent-K crossing of percent D only after both lines have already entered the overbought zone or the oversold zone.
  • Price-indicator divergence is a separate cue: a market low or market high that percent D does not confirm.
Entries in this reading2 entries

A range-normalized close

A stochastic oscillator is a 0-to-100 reading that locates the latest close inside a chosen window of the highest high and lowest low. The construction assumes that closes gather near range lows while price is falling and near range highs while price is rising. The same construction can be applied to monthly, weekly, or intradaily bars.

Assembling raw percent K

In the worked construction, raw percent K uses a five-bar lookback. It is 100 times the current close minus the five-bar lowest low, divided by the five-bar high-low span. That unsmoothed value is computed from the current close and the lookback extremes.

Deriving percent D

Percent D is the three-bar smoothed companion of percent K. It is formed as 100 times the three-period sum of close-minus-lowest-low divided by the three-period sum of highest-high-minus-lowest-low.

Plotting the two lines

When the two lines are plotted, the vertical axis is the stochastic percentage and the horizontal axis is time. The overbought zone is the upper band of the oscillator scale, conventionally 80 and above. The oversold zone is the lower band, conventionally 20 and below.

The zone-and-cross cue

A percent-K crossing of percent D is treated as a trend-change cue only after both lines have already entered the overbought zone or the oversold zone. That restricted crossing is the zone-and-cross cue.

Price-indicator divergence

A second cue is price-indicator divergence between price and percent D: a market low that percent D does not confirm, or a market high that percent D does not confirm. A new price extreme that the percent-D line does not confirm is treated as a separate reversal hypothesis.

Educational research material, not investment advice. Historical source context does not establish present-day performance.
4 of 16 in the Price-indicator divergence track
19931-8 pp.Next on Price-indicator divergenceRelative strength index events depend on the chosen input combinationA conventional relative strength index compares average upward closes with average downward closes over a stated lookback, commonly 14 periods, and stays bounded between 0 and 100.
All readings on this track · 16 readings
  1. 1989Volume confirmation windows and exponential average construction
  2. 1990Constructing stochastic %K and %D from range position
  3. 1990Build a weekly leading sector composite from scaled transports and financials
  4. 1990Constructing stochastic K and D lines and divergence cues
  5. 1993Relative strength index events depend on the chosen input combination
  6. 1995Constructing a dual-horizon force index
  7. 1996Building a range-normalized divergence index from relative strength index
  8. 1998Treat RSI as a testable filter rather than a trigger
  9. 1999Primary-cycle windows, then stochastic confirmation
  10. 1999Stochastic rules versus buy and hold
  11. 2001Constructing confirmation filters for RSI overbought and oversold extremes
  12. 2003Constructing divergence-equivalent relative strength index and stochastic oscillators
  13. 2003Reverse-engineered RSI as a next-close projection
  14. 2003Scoring open versus resolved relative strength divergences
  15. 2003Bull-and-bear-balance from OHLC bar patterns
  16. 2003Constructing bull and bear balance from session paths
All 19 readings tagged Price-indicator divergence
Also on Price-indicator divergence5 readings