# Mean Deviation (MEANDEVIATION)

> QuantNexus indicator page for average distance from a moving average.

**Route**: `/quantnexus/indicators/meandeviation/`

## What It Does

MEANDEVIATION measures how far price typically moves away from its moving-average baseline over the lookback window.

## Formula

`Mean Deviation = average(|Price - Moving Average|)`

## Parameters

- `period` - default `20`
- `movav` - default `MovingAverageSimple`

## C++23 API

```cpp
#include <nonabt/indicators/meandeviation.hpp>
auto meanDev = std::make_unique<nonabt::MEANDEVIATION>(data().close(), 20, "MovingAverageSimple");
```

## Common Usage

- Use it as a volatility context measure around a baseline.
- Combine it with band-style systems or breakout filters.
- Helpful when you need a direct average-distance reading instead of a standard deviation.
