Kase Peak Oscillator is the difference between two trend measurements, one for rising markets and the other for falling markets. KCD is the PeakOsc minus its own average. So, KPO takes the place of a traditional oscillator and the KCD takes place of the traditional .
Ms .Kase claims KCD is far more accurate than .
Let me know if you have experience with the original indicators and are willing to help improve these clones. Thanks.
// // @author LazyBear // If you use this code, in its original or modified form, appreciate if you could // drop me a note. Thx. // study(title="Kase Peak Oscillator [LazyBear]", shorttitle="KPO_LB") length=input(30, title="Length") rwh=(high-low[length])/(atr(length)*sqrt(length)) rwl=(high[length]-low)/(atr(length)*sqrt(length)) pk=wma((rwh-rwl),3) mn=sma(pk,length) sd=stdev(pk,length) v1=iff(mn+(1.33*sd)>2.08,mn+(1.33*sd),2.08) v2=iff(mn-(1.33*sd)<-1.92,mn-(1.33*sd),-1.92) ln=iff(pk>=0 and pk>0,v1,iff(pk<=0 and pk<0,v2,0)) rbars=iff(pk>pk,pk,0) gbars=iff(pk>pk,pk,0) plot(rbars, style=histogram, color=red) plot(gbars, style=histogram, color=green) plot(ln, color=yellow, linewidth=1)