Skip to main content

stoch

Calculate the Stochastic Oscillator.

The Stochastic Oscillator measures where the close is in relation to the recent trading range. The values range from zero to 100. %D values over 75 indicate an overbought condition; values under 25 indicate an oversold condition. When the Fast %D crosses above the Slow %D, it is a buy signal; when it crosses below, it is a sell signal. The Raw %K is generally considered too erratic to use for crossover signals.

Parameters

data: ForwardRef('Data') | ForwardRef('DataFrame') | ForwardRef('Series') | ForwardRef('ndarray') | dict | list
index: str
Default: date
fast_k_period: int
Default: 14
slow_d_period: int
Default: 3
slow_k_period: int
Default: 3


Returns

results: list[Data]

Serializable results.

provider: str

Provider name.

warnings: Optional[list[Warning_]]

list of warnings.

chart: Optional[Chart]

Chart object.

extra: dict[str, Any]

Extra info.


Data