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: list[openbb_core.provider.abstract.data.Data]

The data to use for the Stochastic Oscillator calculation.

Optional: False


index: str

Index column name to use with data, by default 'date'.

Default: date

Optional: True


fast_k_period: int

The fast %K period, by default 14.

Default: 14

Optional: True


slow_d_period: int

The slow %D period, by default 3.

Default: 3

Optional: True


slow_k_period: int

The slow %K period, by default 3.

Default: 3

Optional: True


Returns

results: list[Data]

Serializable results.


provider: None

Provider name.


warnings: Optional[list[Warning_]]

list of warnings.


chart: Optional[Chart]

Chart object.


extra: dict[str, Any]

Extra info.


On this page