Skip to content
Algo Trade Analytics Docs

ta.stoch() - Pine Script Function

Stochastic. It is calculated by a formula: 100 * (close - lowest(low, length)) / (highest(high, length) - lowest(low, length)).

ta.stoch(source, high, low, length) → series float
NameTypeDescription
sourceseries int/floatSource series.

Stochastic.

  • na values in the source series are ignored.