mbarcala
Active member
Here is another version of Bull and Bear Strength from TradingView converted to thinkscript.
Original Link: https://www.tradingview.com/script/ZFfiy0mr/
Upper Indicator here: https://usethinkscript.com/threads/break-keltner-bands-bkb-for-thinkorswim.11220/
script here
Original Link: https://www.tradingview.com/script/ZFfiy0mr/
Upper Indicator here: https://usethinkscript.com/threads/break-keltner-bands-bkb-for-thinkorswim.11220/
script here
Code:
# Bull and Bear Strength from TradingView converted by mbarcala
#Original link: https://www.tradingview.com/script/ZFfiy0mr/
declare lower;
input length = 20;
input bullper = 13;
input bearper = 13;
def Mdb = ExpAverage(close, length);
def bull = high - ExpAverage(close, bullper);
def bear = low - ExpAverage(close, bearper);
plot upLine = close - Mdb;
upLine.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
upLine.AssignValueColor(if upLine > 2.0 then CreateColor(0,102,204) else Color.CURRENT);
upLine.HideBubble();
plot downLine = -(bull + bear);
downLine.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
downLine.AssignValueColor(if downLine > 2.0 then Color.RED else Color.CURRENT);
downLine.HideBubble();
plot centerLine = 0;
centerLine.SetDefaultColor(Color.GRAY);
Last edited: