# Williams A/D

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

Plots Larry Williams' cumulative accumulation/distribution line in its original price-only form: each bar adds the close's progress from the true low on up-closes and subtracts its distance from the true high on down-closes, with an optional volume-weighted variant. A 20-period EMA smoothing, directional coloring and automatic divergence detection complete the build.

- Indicator in the LuxAlgo Library, by LuxAlgo, published Jun 3, 2026.
- Access: free.
- Concepts: [Williams A/D](https://www.luxalgo.com/library/concept/williams-a-d/) (primary)
- Open on Vela: https://vela.luxalgo.com/chart?pineScriptCodeId=g2h588tbnw064zjpr336hykn
- Page: https://www.luxalgo.com/library/indicator/williams-a-d/

**Williams A/D** accumulates a simple per-bar verdict (how much ground the close won from the true low on up-closes, or surrendered from the true high on down-closes) into the running line Larry Williams read for quiet accumulation and distribution. This is the first faithful rendering of [Williams A/D](https://www.luxalgo.com/library/concept/williams-a-d/) in its original price-only form: the line colors by its own direction, an optional moving average smooths it, and regular divergences against price are detected from pivots, drawn dashed and labeled.

## How to Trade the Williams A/D?

- **Bullish divergence**: price stamps a lower low but the line bottoms higher, the primary application, alerted when the confirming pivot completes.
- **Bearish divergence**: a higher price high against a lower high on the line, likewise drawn and alerted.
- **Smoothing crosses**: the line crossing its moving average reads slope-regime turns after long drifts, with alerts both ways.

Only direction, slope and divergence carry information, never the absolute level.

## Williams A/D Settings

- **Volume-Weighted Variant** (default off): the original uses no volume at all; enable to multiply each bar's contribution by volume.
- **Smoothing Method** (default EMA) and **Smoothing Length** (default 20): the moving average of the line; None disables it.
- **Show Divergences** (default on): draw and label regular divergences.
- **Pivot Lookback** (default 5): bars each side confirming a pivot on the line; higher values return more significant pivots, later.
- **Maximum Pivot Distance** (default 60): furthest apart two compared pivots may sit.
- Style: **Directional Coloring** (on) and **Gradient Fill** (on) between line and smoothing.

## Frequently Asked Questions

### How is Williams A/D different from the Accumulation/Distribution Line?

The [Accumulation/Distribution](https://www.luxalgo.com/library/indicator/accumulation-distribution/) line scales every bar's contribution by volume and by the close's position inside that bar's range. Williams' construction ignores volume and measures the close against the true low or high (extended across gaps by the previous close), so gaps register, and volume stays optional.

### Why does the line's value look arbitrary?

Because it is: the sum is seeded at zero on the first loaded bar, so more history shifts every reading. The build leaves the scale raw on purpose: slope, turns and divergence are the whole read; comparisons across symbols mean nothing.

### When should I enable the volume weighting?

When each bar's verdict should scale with participation rather than bar anatomy alone. The price-only default is the faithful original; the weighted variant behaves more like other cumulative volume-flow lines while keeping the up-close and down-close logic.

## Related indicators

- [Oscillator Matrix](https://www.luxalgo.com/library/indicator/luxalgo-oscillator-matrix/) (Money Flow Index): markdown at https://www.luxalgo.com/library/indicator/luxalgo-oscillator-matrix.md
- [LuxAlgo - Screener (OSC)](https://www.luxalgo.com/library/indicator/luxalgo-screener-osc/) (Money Flow Index): markdown at https://www.luxalgo.com/library/indicator/luxalgo-screener-osc.md
- [Delta ZigZag](https://www.luxalgo.com/library/indicator/delta-zigzag/) (Weis Wave Volume): markdown at https://www.luxalgo.com/library/indicator/delta-zigzag.md
- [Price Zone Oscillator](https://www.luxalgo.com/library/indicator/price-zone-oscillator/) (Volume & Order Flow): markdown at https://www.luxalgo.com/library/indicator/price-zone-oscillator.md
- [OBV Divergence](https://www.luxalgo.com/library/indicator/obv-divergence/) (Volume & Order Flow): markdown at https://www.luxalgo.com/library/indicator/obv-divergence.md
- [Smart Money Index](https://www.luxalgo.com/library/indicator/smart-money-index/) (Volume & Order Flow): markdown at https://www.luxalgo.com/library/indicator/smart-money-index.md
- [Trade Volume Index](https://www.luxalgo.com/library/indicator/trade-volume-index/) (Volume & Order Flow): markdown at https://www.luxalgo.com/library/indicator/trade-volume-index.md
- [Volume Flow Indicator](https://www.luxalgo.com/library/indicator/volume-flow-indicator/) (Volume & Order Flow): markdown at https://www.luxalgo.com/library/indicator/volume-flow-indicator.md

---

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