Documentation

Choosing a chart

Six peer chart modules, each answering one kind of question and owning its own transition rules.

Each chart module is an independent peer. Its builder adds chart-specific methods to the shared grammar, and the module decides how its marks move. Both endpoints of a transition must use the same chart type.

ChartQuestion it answersChart-owned rule
BarHow do categories compare?Bars share a quantitative baseline
LineHow does a value change in order?Keys identify points inside paths; gaps stay honest
AreaHow does magnitude or composition change?Explicit baseline and stacked boundaries
PointHow do two quantities relate?Compact Cartesian axes; entering points grow in place
UnitHow many countable items are there?Grid, force, unit-bar and beeswarm layouts; shortest travel
PieWhat share of one total does each part take?Keyed angular motion; direct transitions only

Every chart can also be partitioned into small multiples with .repeat().

Import only what you use

import { line } from 'visdelta/line';

const chart = line(rows)
  .x('date', { type: 'temporal' })
  .y('close');

A builder carries its chart module, so transition() loads only the renderer it needs.

Design warnings

Each chart module can also report advisory design warnings, such as too many stacked columns or a truncated bar baseline. They never change what renders. See Visualization warnings.

On this page