Enkindel

Medium-Slow QG3

Color coded moving average cross overs.
Edited by Enkindel, original code by ChrisMoody, QG3 system by QuadG
Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.

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.

Want to use this script on a chart?
// Created By User ChrisMoody / Modified by Enkindel using QG3 system by QuadG
study(title = "Medium-Slow QG3", shorttitle="Medium-Slow QG3", overlay=true)

src = close, len = input(3, minval=1, title="Fast EMA")
src2 = close, len2 = input(10, minval=1, title="Medium EMA")
src3 = close, len3 = input(20, minval=1, title="Slow MA")

emaFast = ema(src, len)
emaMedium = ema(src2, len2)
smaSlow = sma(src3, len3)

plot_color = emaFast >= emaMedium and emaMedium >= smaSlow ? green : emaFast < emaMedium and emaMedium < smaSlow ? red : yellow

p1 = plot(emaMedium, title="EMA Medium", style=line, linewidth=4, color = plot_color)
p2 = plot(smaSlow, title="MA Slow", style=line, linewidth=4, color = plot_color)

fill(p1, p2, color=white, transp=40, title="Fill")