OPEN-SOURCE SCRIPT

Narayan Candle Up/Down Indicator

68
//version=5
indicator("Candle Up/Down Indicator", overlay=true)

// Candle colors
candleColor = close > open ? color.green : close < open ? color.red : color.gray

// Plot candles as background
bgcolor(candleColor, transp=80)

// Optional: plot arrow on up/down
plotshape(close > open, title="Up Candle", location=location.belowbar, color=color.green, style=shape.triangleup, size=size.tiny)
plotshape(close < open, title="Down Candle", location=location.abovebar, color=color.red, style=shape.triangledown, size=size.tiny)

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.