worldsapart89

Simple and Exponential Moving Averages

This script graphs 5 SMAs (20, 50, 100, 150, 200) and 5 EMAs (20, 50, 100, 150, 200). The first group uses blue and orange colors whereas the second one uses green and red. When a bar closes below a moving average, either orange or red will be used depending on which type of moving average and which period. In bullish mode, we show blue and green. Moving average periods are configurable, and you can hide the MAs you don't want.
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?