lix

LX Rsi Divergence Bars

This script colours the bars when they are below or boyond a specified RSI threshold
Remove from Favorite Scripts Add to Favorite Scripts
study("LX Rsi Divergence Bars", shorttitle="LiX_RSIBARS", overlay=true)
//r = rising(ohlc4,6)
//rb = close + highestbars(close,6)
rsiperiod = input(title="RSI Period", type=integer, defval=21)
overb = input(title="Overbought", type=integer, defval=70)
oversold = input(title="Oversold", type=integer, defval=30)
rsbar = rsi(close,rsiperiod)
//clr = rsbar > 60 ? open < close ? 4 : na : na
//plot(clr,title="200 price",color=#3399FF,transp=90)
//bgcolor(close < open ? red : green, transp=70)
//barcolor(close < open ? silver : #3C78D8)
barcolor(rsbar >= overb ? open < close ? green : na : na) // moves in the trend of overbought
barcolor(rsbar >= overb ? open > close ? red : na : na) // diverging bar

barcolor(rsbar <= oversold ? open < close ? green : na : na) // diverging bar
barcolor(rsbar <= oversold ? open > close ? gray : na : na) // moves in the trend of oversold
This script has been tremendously advantageous; appreciate it.
Reply
lix Cryptocontinuum
@Cryptocontinuum, glad it was useful :)
Reply
Home Stock Screener Forex Screener Crypto Screener Economic Calendar Shows How It Works Chart Features Pricing House Rules Moderators Website & Broker Solutions Widgets Charting Solutions Lightweight Charting Library Help Center Refer a friend Feature Request Blog & News FAQ Wiki Twitter
Profile Profile Settings Account and Billing Refer a friend My Support Tickets Help Center Ideas Published Followers Following Private Messages Chat Sign Out