This script plots the RSI and highlights overbought and oversold zones:
//@version=5
indicator("RSI Indicator for Binance", overlay=false)
// === INPUTS ===
rsiLength = input.int(14, title="RSI Period")
overbought = input.int(70, title="Overbought Level")
oversold = input.int(30, title="Oversold Level")
src = input.source(close, title="Source")
// === RSI CALCULATION ===
rsi = ta.rsi(src, rsiLength)
// === PLOT RSI ===
plot(rsi, color=color.blue, title="RSI")
hline(overbought, "Overbought", color=color.red)
hline(oversold, "Oversold", color=color.green)
hline(50, "Middle Line", color=color.gray)
// === BACKGROUND COLOR ALERTS ===
bgcolor(rsi > overbought ? color.new(color.red, 85) : na)
bgcolor(rsi < oversold ? color.new(color.green, 85) : na)
How to Use:
1. Open TradingView.
2. Open any Binance trading pair chart (e.g., BTC/USDT).
#indicador #Analaysis๐ฅ๐ฅ๐ฅ๐ฅ๐ #coding #FOMCMeeting $BTC