For a dive into the fine details, see the source code/documentation.

Quad MA is a program designed to allow a wide range of flexibility in overlaying multiple moving averages onto a chart.

This program handles the ability to:
- Overlay Up to 4 moving averages on the chart.
- Change the length of each moving average.
- Adjust optional values for special moving averages
(least squares and Arnaud Legoux )
- Change the color for each moving average.
- Change the type of each moving average individually.
- Change the visibility of each moving average.
- Change the source of the moving averages.
- Set alerts for a cross between any two moving averages.

Release Notes: Polishing comments, update posted before study() detailing my intention to work on code in java to reproduce this script with any number of moving averages.
Release Notes: Clean Chart update
Release Notes: Trend value input changed to input.source instead.

House-Rules update
Release Notes: Minor Changes to documentation.

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?