OPEN-SOURCE SCRIPT
SPX EMAs - Bala

//version=5
indicator("SPX EMAs", overlay = true)
// Inputs
ema8 = ta.ema(close, 8)
ema21 = ta.ema(close, 21)
ema50 = ta.ema(close, 50)
ema200 = ta.ema(close, 200)
// Plot EMAs
plot(ema8, "EMA 8", color=color.new(color.green, 0), linewidth=2)
plot(ema21, "EMA 21", color=color.new(color.orange, 0), linewidth=2)
plot(ema50, "EMA 50", color=color.new(color.blue, 0), linewidth=2)
plot(ema200,"EMA 200",color=color.new(color.red, 0), linewidth=2)
indicator("SPX EMAs", overlay = true)
// Inputs
ema8 = ta.ema(close, 8)
ema21 = ta.ema(close, 21)
ema50 = ta.ema(close, 50)
ema200 = ta.ema(close, 200)
// Plot EMAs
plot(ema8, "EMA 8", color=color.new(color.green, 0), linewidth=2)
plot(ema21, "EMA 21", color=color.new(color.orange, 0), linewidth=2)
plot(ema50, "EMA 50", color=color.new(color.blue, 0), linewidth=2)
plot(ema200,"EMA 200",color=color.new(color.red, 0), linewidth=2)
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
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.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
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.