Docs Visualizations
The chart catalogue
Twelve curated chart kinds, each with explicit when-to-use guidance for humans and AI alike.
ST-1 ships a small, opinionated catalogue rather than a generic plotting library. Every kind has a single shape it’s good for, a clear failure mode, and a default that works on most datasets without configuration. The same metadata drives the in-app picker, the MCP tool descriptions an AI sees, and this page — so what you read here is exactly what your AI client sees when it’s deciding which chart to make.
The catalogue
Each entry shows the kind’s identifier (the value of spec.kind) followed by its label, what it does, and when to reach for it.
barBar chartCounts (or a numeric aggregation) grouped by a categorical column.
Use when Compare a numeric value across a small set of categories (≤ ~20). Sorted by value by default; pass x_order for ordinal categories like age bands or quintiles.
Avoid when Avoid when there are >30 categories — bars become illegible; use a horizontal bar or lollipop and rank instead. Avoid when the goal is part-to-whole — use stacked bar or waffle.
bar_horizontalHorizontal bar chartBar chart with categorical Y and numeric X.
Use when Same as bar, but for ranked comparisons or when category labels are long. Always sorts by value unless y_order is provided.
Avoid when Avoid when X is a time axis — readers expect time on horizontal.
bar_stackedStacked bar chartBars stacked by a second categorical (the parts).
Use when Show part-to-whole composition across categories or time, when you care about both the totals AND the mix within each. Color column is required — it defines the stack.
Avoid when Avoid with >5 stack layers — comparison across non-baseline segments becomes guesswork; use small multiples (faceted bar) instead.
lollipopLollipop chartRanked categorical comparison drawn as rules + dots.
Use when Replacement for a bar chart when bars feel ink-heavy — same data shape, lighter visually. Especially good for ranked top-N lists with 10–30 categories.
Avoid when Avoid when the message is part-to-whole or when bars are needed for visual weight (e.g. presentation slides where readers skim).
histogramHistogramDistribution of a single numeric column, binned automatically.
Use when First look at any numeric column — see shape, skew, outliers, modality. Use before deciding whether mean/median is the right summary.
Avoid when Avoid for tiny samples (<30 rows) — bins lie. Use a strip plot to see every point. For comparing distributions across groups, use a faceted histogram or density plot.
stripStrip plotOne dot per row across categorical x, numeric y.
Use when See every observation across a small set of groups (<10 categories, <2k rows). Better than a boxplot when individual outliers matter or sample sizes are small.
Avoid when Avoid with >5k rows — overplotting hides the pattern; use a hexbin or faceted histogram instead.
scatterScatter plotTwo numeric columns; optional categorical color.
Use when Look for relationships, clusters, or outliers between two numeric variables. Add a color column to spot group structure.
Avoid when Avoid with >50k rows — overplotting masks density; use hexbin or 2D histogram. Not for showing a trend through time — use a line chart.
lineLine chartNumeric or temporal X, numeric Y. Lines per optional series column.
Use when Show how a numeric value changes along an ordered axis — usually time. Use color to compare a few series (≤6).
Avoid when Avoid when X is unordered categorical — use a bar chart. Avoid with >10 series — the spaghetti hides the message; use small multiples.
areaArea chartFilled line — same axes as line.
Use when When the magnitude of the value matters as much as the trend — e.g. cumulative volumes over time. Stack with color for compositions over time.
Avoid when Avoid for non-cumulative comparisons — readers misread the heights as additive when they're not.
heatmapHeatmapGrid of cells coloured by an aggregation across two categoricals.
Use when Show density or aggregated value across two categorical (or binned numeric) axes — e.g. day-of-week × hour, source × destination.
Avoid when Avoid with sparse matrices (most cells empty) — use a bar chart of the populated combos. Avoid with grids larger than ~50×50 — bin coarser first.
waffleWaffle chartTile-grid bar where each tile represents a unit count.
Use when Part-to-whole over a small set of categories (≤8). Reads as discrete units, which is friendlier than a pie or stacked bar for headcounts and proportions.
Avoid when Avoid with >10 categories or when exact counts matter — tiles round. Avoid for ordered comparisons — use a bar chart.
point_mapPoint mapLatitude / longitude points projected onto a world map.
Use when Plot geographic events or locations — taxi pickups, store locations, observation sites. Add color to surface group structure or a value gradient. Filters propagate so you can brush a histogram and watch the map update.
Avoid when Avoid for >100k rows without sampling — the dots overplot into a blob. For region-level summaries (countries, states), a choropleth or bubble map is the right pick.
Spec format
Every visualization is a JSON object: a kind string and an optionsmap. The web UI’s edit page and the MCP create_visualization tool both write the same shape — readable, diffable, redoable from the SQL.