Cohort chart reference
Contents: Use cases, Chart IDs, Minimal spec, Data, Options, Annotations, Exclude a running period, Cumulative conversion from counts, Sizing, Fixtures, Not for.
Cohorts by periods-since-start: counts in, every retention rate derived, weighted averages that are never the mean of percentages. Type cohort. Aliases: retention.
Use cases
- Retention by signup cohort
- Repeat purchase by first month
- Subscription churn by start month
Chart IDs
cohort.heatmap: fixturesaas-logo-retentioncohort.pure: fixtureretention-pure-exhibitcohort.stepped: fixtureretention-stepped-column
Minimal spec
{
"type": "cohort",
"data": {
"periodLabel": "Month",
"cohorts": [
{ "id": "jan", "label": "Jan 2026", "active": [100, 70, 60], "size": 100 },
{ "id": "feb", "label": "Feb 2026", "active": [80, 60], "size": 80 }
]
},
"options": {
"unit": "% of cohort base",
"title": "January retains 60% of its customers at month two",
"source": "Illustrative data"
}
}Data
| Path | Type | Required | Meaning |
|---|---|---|---|
| periodLabel | string | Period unit, e.g. 'Month' -> columns M0, M1, ...; omitted gives 'Period 0'. | |
| cohorts | array | yes | At least two cohorts in chronological order, oldest first. |
| cohorts[].id | string | yes | Unique cohort identity; the computed average-row id is reserved. |
| cohorts[].label | string | Displayed cohort name; defaults to its id. | |
| cohorts[].active | array | yes | Whole nonnegative active-member counts from period zero onward; null is a missing count. The first count must be a known positive cohort base; shorter rows leave later periods unobserved. |
| cohorts[].size | integer | Declared cohort base; VERIFIED against active[0], never used in its place. |
Options
| Path | Type | Values | Default | Meaning |
|---|---|---|---|---|
| format | string | Rate format in percentage units, such as '1.0%' or '1.00' for two decimals without a sign on exhibit tables. Without a format the rates of the chart are one percent set under the default rule, and the heatmap keeps the set's decimals. The M0 anchor is neutral and the color scale stays fixed at 0–100%. | ||
| basis | string | 'cohort', 'previous' | 'cohort' | 'cohort' = active / cohort base (comparable down a column); 'previous' = active / the previous period's active. |
| averages | false | string | false, 'weighted' | false | Heatmap only. Weighted column average = total active / total base of the observed cohorts. |
| methodNote | boolean | Default false. true adds the measure formula and explains the visible anchor column and blank cells. strings.cohortMeasure and strings.cohortFormula name another count-based measure, such as cumulative conversion. Required interpretation notes still print: the formula under basis 'previous', not-meaningful cells, weighted averages and rates too narrow to print. | ||
| variant | string | 'heatmap', 'pure', 'stepped' | 'heatmap' | Form. 'heatmap' (the default) draws the heatmap surface, which honors 'labels'. 'pure' and 'stepped' draw the exhibit. Stepped columns share the width the label and size columns leave, as pure columns do, and preserve weighted-average and missing-cell notes. The exhibit variants draw a fixed label set, so authoring 'labels' together with variant is refused (the legacy surface honors it). |
| formatScope | string | 'classic', 'column' | Stepped fills use absolute bins ('classic') or normalize within each period ('column'). | |
| steps | array | Four ascending thresholds in percentage points that split the absolute ('classic') stepped fills into five classes the key names, such as [70, 80, 85, 90] for period-to-period retention. Default [30, 40, 50, 60]. | ||
| visiblePeriods | array | Original zero-based period indices displayed in chronological order. A hidden period leaves no cell, head, note or record; rates and averages are still derived over all periods. | ||
| cohortSizeLabel | string | Header for the exhibit cohort-size column; defaults to Cohort size. | ||
| showPercentSign | boolean | Print a percent sign in every exhibit cell; defaults to false because the unit is stated once. | ||
| threshold | number | false | false (or another value of its type) | Pure-exhibit emphasis threshold in percentage points: cohort and total rates above it print bold; period 0 stays neutral. A note prints only when a visible cell uses that emphasis. Defaults to 60; false disables emphasis and its note. | |
| designatedPeriod | integer | false | false (or another value of its type) | Original zero-based period index receiving the pure-exhibit column tint; defaults to 3. false draws no tint and no head emphasis, on variant 'pure' only. | |
| total | false | string | false, 'weighted' | Summary row. Exhibit: weighted retention by default, or false to hide it. Heatmap: 'weighted' equals averages 'weighted', false hides the average row, and total wins over averages. Never averages cohort percentages equally. | |
| totalPosition | string | 'top', 'bottom' | Exhibit variants: where the summary row stands, with its ground, rules and average bases; default 'bottom'. With total false it warns option-ignored. | |
| columnVisibility | object | True shows a column and false leaves it out: the ids are data.columnToggles ids on table and column ids elsewhere. Ids: size. | ||
| columnOverrides | object | Settings per generated column. Ids: label, size, periods. A periods width is per period column and replaces the shared width, and the room it leaves stays empty on the right of the table. label on periods warns, because each period keeps its own head. label on the label track sets the corner head, and label on size beats cohortSizeLabel. | ||
| columnOverrides.*.width | number | Track width in px. It beats the width the type would pick. | ||
| columnOverrides.*.align | string | 'left', 'right', 'center' | Alignment of the column: its cell text and, unless headAlign is set, its head. Bars keep starting at the panel origin. | |
| columnOverrides.*.headAlign | string | 'left', 'right', 'center' | Head alignment; defaults to align. | |
| columnOverrides.*.label | string | Head text. | ||
| columnOrder | array | Order of whole blocks; blocks left out follow in default order. Ids: size, periods. | ||
| columnHeads | false | false | false: no visible head row and no group heads, with their height and rule. Assistive technology still reads the head in React, and sortable warns there. | |
| figures | false | false | Variant 'stepped': false stops the numbers on filled cells. Period 0 and other cells with no fill keep their text. Hover, records and accessible values stay. | |
| excludeCurrentPeriod | boolean | Remove the newest cohort and longest period before exhibit derivation. | ||
| exhibitLabel | string | Short exhibit heading above the assertion title. | ||
| heightFill | string | 'rows', 'none' | 'rows' | Exhibit variants. 'rows' (default): rows take the spare height of a pinned canvas, up to 1.8 times, and stepped columns share the free width. 'none': natural row height, stepped columns at measured width. |
Plus the shared options. This type does not accept detailFields, labelPosition, valueAxis, rounding, annotations. This type ignores animate, debug, rowLabels, categoryAxis, categoryLabels, secondaryAxis, topN, bandFraction, valueAxis.show, valueAxis.gridlines with an option-ignored warning.
Annotations
This type takes no annotations.
Exclude a running period
On exhibit tables, excludeCurrentPeriod: true removes the newest cohort and the last observation of each earlier cohort. A disclosure names the removed cohort and explains both removals. Every render target keeps this disclosure with footnotes: false.
The disclosure also appears in reading.notes. It does not add structured records for removed cells. visiblePeriods is a separate display filter.
Cumulative conversion from counts
Set strings.cohortMeasure to the measure name and strings.cohortFormula to its formula sentence. The strings change the notes, key caption and accessible description. They do not change the calculation.
Automatic exhibit formats keep the default rounding. A nonzero rate that would print as zero gets only the extra decimals needed to show a nonzero digit. Other rates keep their precision. Authored formats stay unchanged. A pure exhibit uses scientific notation for a zeroed rate only when its decimal text cannot fit.
Bare rate cells get their unit once, in a header line that already exists: the stepped key caption ("Retention in %"), or the corner cell above the cohort labels in pure tables and stepped tables without a key. The default is %. A visible classic key keeps an authored unit there. Only structured fields count as showing the unit: unitShown: true, a value format that prints it, a custom measure or subtitle measure that names it, or unit with a subtitle. A % in the title or in another subtitle field does not count. If fitting cuts the subtitle, the header still names the unit. The table size, calculations and number formatting do not change.
Keep basis: "cohort". Put the eligible cohort count in active[0] and the cumulative converted count in each later period. Boardplot divides each later count by active[0]. Set visiblePeriods to the later periods so the base column does not appear as a conversion result. Short rows leave later periods unobserved. The fixtures cumulative-conversion-pure and cumulative-conversion-stepped show both exhibit styles.
{
"type": "cohort",
"data": {
"periodLabel": "Week",
"cohorts": [
{ "id": "a", "label": "Batch A", "active": [1000, 5, 12] },
{ "id": "b", "label": "Batch B", "active": [800, 4] }
]
},
"options": {
"title": "Cumulative conversion rises by the second week",
"variant": "stepped",
"formatScope": "classic",
"basis": "cohort",
"unit": "%",
"visiblePeriods": [1, 2],
"steps": [0.5, 1, 2, 3],
"methodNote": true,
"size": { "width": 1100 },
"strings": {
"cohortMeasure": "Cumulative conversion",
"cohortFormula": "Cumulative conversion = converted so far / cohort base."
}
}
}Sizing
Floor 280 × 28 px; fit content.
Below the floor a render is refused with size-below-floor and the pixels it needs. measure returns the natural and comfortable size for a given spec; see Sizing in the manual.
Fixtures
| ID | Kind | Use case |
|---|---|---|
| retention-pure-exhibit | example | Pure Exhibit cohort table with a dedicated size column and weighted total |
| retention-stepped-column | example | Stepped cohort table with column-normalized fills and an incomplete-month exclusion |
| saas-logo-retention | example | Logo retention triangle: month-3 retention climbs from 50% to 64% across the 2025 cohorts |
| program-participation-quarterly | example | Quarterly participation triangle with weighted averages: 60% at quarter 1, on a support base that halves by quarter 3 |
| retention-24x24-resurrection | torture | Torture: 24 weekly cohorts x 24 periods, long cohort labels, one resurrection cell and one pilot cohort down to a single member |
| missing-counts | torture | Missing counts leave rates and dependent totals unknown |
| retention-stepped-content | example | Measured cohort columns and a separated weighted average |
| retention-previous-period | example | Period-to-period retention with absolute stepped fills and no total row |
| logo-retention-method-note | example | Logo retention with the retention formula and the anchor column explained |
| crowded-average-bases | torture | Hidden average bases name their periods |
| emphasis-disabled | example | Pure cohort without threshold emphasis |
| fractional-step-key | torture | Cohort classes keep fractional open upper bounds |
| cumulative-conversion-pure | example | Count-derived cumulative conversion with its own wording |
| cumulative-conversion-stepped | example | Count-derived cumulative conversion with its own wording |
| no-size-column | example | Pure exhibit without the size column, whose bases stay in the weighted total |
| column-tracks | example | Pure exhibit with authored track widths, alignment and heads |
| size-after-periods | example | Stepped exhibit with the size column after the periods |
| no-column-heads | example | Pure exhibit without its head row, with the periods named in the subtitle |
| no-column-heads-stepped | example | Stepped exhibit without heads or the range lines under them |
| total-top | example | Stepped exhibit with the weighted average above the cohorts |
| no-designated-period | example | Pure exhibit with no tinted column |
| stepped-no-figures | example | Stepped exhibit whose fills carry the rates without printed numbers |
| heatmap-weighted-total | example | Heatmap with the weighted average row set by total |
| heatmap-visible-periods | example | Heatmap showing the later periods only, with no trace of the hidden ones |
Not for
Precomputed retention percentages; cohort takes active-member counts and derives the rates.