# MA of MA

MA of MA is an indicator on [Vela](https://vela.luxalgo.com/chart), our next-generation charting platform, written in Pine Script®.

Overlay that smooths a moving average with a second moving average, defaulting to a 20-period EMA fed into another 20-period EMA across six selectable average types. A dashboard totals each pass's nominal lag in bars, an optional lag-reduced line cancels most of it, and crossings fire turn alerts. For trend traders who want a stable baseline with its lag quantified.

- Indicator in the LuxAlgo Library, by LuxAlgo, published Jun 10, 2026.
- Access: free.
- Concepts: [MA of MA](https://www.luxalgo.com/library/concept/ma-of-ma/) (primary)
- Open on Vela: https://vela.luxalgo.com/chart?pineScriptCodeId=li1pnc2jy8vrv4mi33t2kli9
- Page: https://www.luxalgo.com/library/indicator/ma-of-ma/

**MA of MA** feeds one moving average into another and plots both lines on the price chart, the reference build of the [MA of MA](https://www.luxalgo.com/library/concept/ma-of-ma/) cascade. Each pass picks its own type (SMA, EMA, WMA, RMA, HMA or VWMA) and length, defaulting to an EMA 20 smoothed by a second EMA 20, and a dashboard totals the stack's nominal lag in bars. An optional lag-reduced line turns the same two passes into a DEMA-style fast line instead.

## How to Trade the MA of MA?

- **First MA crosses the MA of MA**: the fast line turning through its double-smoothed copy approximates a slope change of the first average, the turn-detector read.
- **Source crosses the MA of MA**: price reclaiming or losing the slow baseline is the regime signal, with alerts both ways.
- **MA of MA slope flips**: with slope coloring on, the line paints by its own direction and changes state rarely by construction.
- **Widening gap**: the gradient fill between the fast series and the baseline deepens as a trend accelerates.

Every signal arrives later than its single-average equivalent. That is the deal; check the effective-lag row against your holding period, and compare with the other [trend tools](https://www.luxalgo.com/library/family/trend/).

## MA of MA Settings

- **Source** (default close): series fed into the first pass; jagged inputs like volume suit double smoothing.
- **First Pass** (default EMA, length 20): the average applied directly to the source.
- **Second Pass** (default EMA, length 20): the average applied to the first average rather than to price; the passes may differ in type and length.
- **Lag-Reduced Line (2 × MA − MA of MA)** (default off): DEMA-style combination that strips out the bulk of the stacked lag.
- **Show Dashboard** (default on), plus Position and Size.
- **Style toggles**: Slope Trend Coloring (on), Gradient Fill (First MA ↔ MA of MA) and MA Crossing Markers (off).

## Frequently Asked Questions

### How is the MA of MA different from TRIX?
[TRIX](https://www.luxalgo.com/library/indicator/trix/) triple-smooths an EMA, then shows its one-bar rate of change in a separate oscillator pane. This build keeps the smoothed level itself on the price chart, working as a baseline and crossover pair. Reach for TRIX when you want the cascade's slope as a number.

### What do the dashboard's lag figures mean?
They are nominal group-delay estimates: an N-period simple average lags price by roughly (N−1)/2 bars, and the two passes' delays roughly sum. The total is exact for simple averages, approximate for recursive types like the EMA.

### Does double smoothing repaint?
No. Both passes are causal averages of current and prior bars, so plotted history is final. The trade-off is lag, not repainting: the line confirms turns late, so the First MA crossing alerts watch the faster first-pass line, while the Source crossing alerts track price against the slow baseline.

## Related indicators

- [Signal Forge](https://www.luxalgo.com/library/indicator/signal-forge/) (Moving Average Crossovers): markdown at https://www.luxalgo.com/library/indicator/signal-forge.md
- [LuxAlgo - Screener (S&O)](https://www.luxalgo.com/library/indicator/luxalgo-screener-s-o/) (Moving Average Crossovers): markdown at https://www.luxalgo.com/library/indicator/luxalgo-screener-s-o.md
- [Signal Moving Average](https://www.luxalgo.com/library/indicator/signal-moving-average/) (Moving Average Crossovers): markdown at https://www.luxalgo.com/library/indicator/signal-moving-average.md
- [Moving Averages Proximity Oscillator](https://www.luxalgo.com/library/indicator/moving-averages-proximity-oscillator/) (MA Ribbon): markdown at https://www.luxalgo.com/library/indicator/moving-averages-proximity-oscillator.md
- [Golden Cross](https://www.luxalgo.com/library/indicator/golden-cross/) (Trend): markdown at https://www.luxalgo.com/library/indicator/golden-cross.md
- [FVG Positioning Average](https://www.luxalgo.com/library/indicator/fvg-positioning-average/) (Dynamic S/R Via MA): markdown at https://www.luxalgo.com/library/indicator/fvg-positioning-average.md
- [Expanded Cloud](https://www.luxalgo.com/library/indicator/expanded-cloud/) (Dynamic S/R Via MA): markdown at https://www.luxalgo.com/library/indicator/expanded-cloud.md
- [MA Sabres](https://www.luxalgo.com/library/indicator/ma-sabres/) (MA Slope Filter): markdown at https://www.luxalgo.com/library/indicator/ma-sabres.md

---

Source: https://www.luxalgo.com/library/indicator/ma-of-ma/ (LuxAlgo Library). Free to use with attribution: https://www.luxalgo.com/library/license/
