RSI %b with highlighted lines of histogram
// // @author WebAction // RSI %b // study(title = "RSI %b", shorttitle="RSI %b") source = close RSI_length = input(14, minval=1) BB_length = input(50, minval=40, maxval=50) BB_stdDev = input(2.1, minval=2.0, maxval=2.1) rsi_s = rsi(source, RSI_length) bb_s = rsi_s basis = sma(bb_s, BB_length) dev = BB_stdDev * stdev(bb_s, BB_length) upper = basis + dev lower = basis - dev b = (rsi_s - lower)/(upper - lower) plot(b, color=(bb_s > upper) ? red : (bb_s < lower) ? green : black, style=histogram, linewidth=4)