Accumulation/Distribution
Volume flowing in or out, weighted by where each candle closes in its range.
Accumulation/Distribution over the last length candles: Σ money flow volume, MFV = ((close − low) − (high − close)) ÷ (high − low) × volume. Summed over a rolling window instead of since an arbitrary first candle, so the value is the same after every restart. A candle without volume adds 0; a flat candle with volume has no close location, so windows holding it are not ready. Mirror: signed (a mirrored close location flips the flow; volume is unchanged).
Settings
| Setting | Default | Range | What it does |
|---|---|---|---|
| length | 20 | 1 to 5000 | Candles summed. |
What it gives
| Output | What it is |
|---|---|
| ad | Money flow volume sum. |
What it reads
It reads the whole candle (open, high, low, close and volume).
Warm-up
With its default settings, Accumulation/Distribution needs 20 closed candles before its first value. A backtest loads them before its start date, so the first trade can already use it.
Related indicators
Used to build: Chaikin Oscillator
Test it
Copy this sentence into the Algonney chat to backtest it:
Backtest a strategy on BTC that uses Accumulation/Distribution with its default settings