Examples
Median And Quartile Band
**Median + interquartile band on a horizontal `BarChart`.** The value axis runs along x, so both analytics land there by default: the band (P25–P75) washes under the bars, the median rule paints over them.
Min Max Lines
*Minimum and maximum lines on an `AreaChart`** — the range the season swings through.
Percentile Overflow
**`{ percentile: 90 }` with `ifOverflow`.** The line is the 90th percentile of the PREVIOUS release (a field the chart does not draw), which sits above this release's whole range. `"clip"` (left, the default) leaves the domain alone and draws nothing; `"extend"` (right) grows the value domain until the line fits.
Std Dev Bands On Scatter
**±1 standard deviation on a `ScatterChart`, on both axes.** One band per axis (`axis: "x"` reduces the x column), plus the two means — the classic "typical campaign" box.
Confidence Band On Distribution
**A 95 % confidence interval of the mean on a `DistributionChart`.** The band (t-based, `{ spread: { ci: 0.95 } }`) washes under the boxes; the pooled average paints over them.
When Condition
**`when` — the show-condition.** The same analytic on two years: the average line only draws while the average clears the 150 k$ target, so the first year (average below target) shows no line at all.
Custom Function Value
**A custom-function value.** `value: (rows, key) => number` covers any statistic the presets do not: here, the average of the last six months, labelled by the caller.
Label Modes
**The four label modes** on one chart: `"none"` (unlabelled — still in the description), `"value"` (the number alone), `"computation"` (the statistic and the number) and a custom string.
Everything Together
**Everything together — an editorial chart.** Three years of revenue with the interquartile band behind, the average over, a linear trend with its 95 % confidence band, and a six-month seasonal forecast. The legend lists the measure, then the two models with their fit; the tooltip adds a muted row per model; the description reads one sentence per analytic.
From Spec
**`ChartSpec.analytics`** — the serialisable form an agent emits: no callbacks, the same kinds and value union. `AutoChart` hands it to the container unchanged.