quql

kalbot RSI

17
kalbot RSI

Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.

Want to use this script on a chart?
// copyleft pavel pavlov
// kalbot rsi
//
study(title="kalbot RSI", shorttitle="kalbot RSI", max_bars_back=99)
//Inputs
src = input(close, title="RSI Source")
lengthRSI = input(14,title="RSI Length", minval=1)
Overbought1=input(70,title="Overbought2", minval=60)
Oversold1=input(30,title="Oversold2", minval=40)
Overbought2=input(80,title="Overbought2", minval=80)
Oversold2=input(20,title="Oversold2", minval=20)
line50=input(50,title="line50", minval=49)
//RSI Calculation
rsi1 = rsi(src, lengthRSI)
//Buy and Sell zones
h0 = hline(Overbought1,title="Overbought1",color=red,linestyle=solid,linewidth=1)
h1 = hline(Oversold1,title="Oversold1",color=lime,linestyle=solid,linewidth=1)
h2 = hline(Overbought2,title="Overbought1",color=yellow,linestyle=solid,linewidth=1)
h3 = hline(Oversold2,title="Oversold1",color=yellow,linestyle=solid,linewidth=1)
h4 = hline(line50,title="line50",color=silver,linestyle=dotted,linewidth=1)
fill(h2,h0, color=red, transp=80)
fill(h3,h1, color=lime, transp=80)
//Plot RSI with Buy and Sell zones
plot(rsi1, title="rsi", color=white)