OPEN-SOURCE SCRIPT

Swing RSI Panel

57
//version=6
indicator("Swing RSI Panel", overlay=false)

// RSI Settings
rsiLength = input.int(14, "RSI Length")
rsiOversold = input.int(40, "RSI Oversold")
rsiOverbought = input.int(60, "RSI Overbought")

// Calculate RSI
rsiValue = ta.rsi(close, rsiLength)

// Plot RSI
plot(rsiValue, "RSI", color=color.purple, linewidth=2)
hline(50, "Midline", color=color.gray, linestyle=hline.style_dotted)
hline(rsiOversold, "Oversold", color=color.green, linestyle=hline.style_dotted)
hline(rsiOverbought, "Overbought", color=color.red, linestyle=hline.style_dotted)

// Fill zones
bgcolor(rsiValue >= rsiOverbought ? color.new(color.red, 90) :
rsiValue <= rsiOversold ? color.new(color.green, 90) : na, title="RSI Zones")

כתב ויתור

המידע והפרסומים אינם אמורים להיות, ואינם מהווים, עצות פיננסיות, השקעות, מסחר או סוגים אחרים של עצות או המלצות שסופקו או מאושרים על ידי TradingView. קרא עוד בתנאים וההגבלות.