Hi,
Calculation Stochastic as used in PRT
hi = highest[14](high)
lo = lowest[14](low)
oscillator = (close – lo) / (hi – lo) * 100
ProcentK = average[3,0](oscillator) // 0=SMA, 1=EMA, 2=WMA
ProcentD = average[5,0](ProcentK) // 0=SMA, 1=EMA, 2=WMA
RETURN ProcentK AS “%K MA”, ProcentD AS “%D MA”
Formule Stochastics in PRT:
Stochastic[14,3](close)
Stochastic[N,K](price)
N=(lookback)period
K=period of the moving average for smoothing the oscillator
Price=Close (source)
In PRT, the Stochastics is always calculated by default with the “Close” but if you want to use other sources you can specify them in (price1, price2, price3).
If you also want to use the %D (average of %K), you must use the following indicator:
StochasticD[N,K,D](Close)
With the input used in your post, the Stochastic looks like this:
Stochastic[25,3](Close)