Skip to content

Ridgeline

Compare the shape of measure distributions on a shared value axis.

Chart ID: ridgeline. Independent import: @revolist/charts/ridgeline.

Loading chart…

Compare density peaks and spread across measures along the shared horizontal axis. Each ridge is scaled to its own peak.

Use one category per row and one or more numeric series. Values are finite numbers or explicit nulls; the row mapper does not group or aggregate repeated keys.

The roles below describe the chart's data contract. Generic category/value roles resolve from the dataset; explicitly bind specialized numeric roles as shown in the complete example.

Data roleField count
category1 or more
series1 or more

Download the complete sample data and settings (JSON). See Data & Configuration for mapping, null values, updates and lifecycle rules.

Install the package using the installation guide, give the host an explicit height, and call createRidgelineChart after the host mounts. This factory fixes the chart type to ridgeline.

<div id="chart" style="width: 100%; height: 450px;"></div>
Complete runnable TypeScript example with sample data
import { createRidgelineChart } from '@revolist/charts/ridgeline';
import sample from './sample-data';
const chart = await createRidgelineChart({
container: document.getElementById('chart')!,
...sample,
});

Await updates before reading a snapshot or exporting. Call chart.destroy() when the host unmounts. See the live catalog to interact with this type.

Set these fields in chartOptions. The option schema validates supported keys, ranges and choices; updating chartOptions replaces that authored object.

OptionDefaultAccepted values
showGridLinestruetrue or false
markOpacity10.2 to 1; step 0.05
pinTooltipsfalsetrue or false

Titles, legends, theme and labels belong to presentation or the corresponding top-level setting. Axis, color, navigation and interaction support depends on the selected chart; see Data & Configuration.

  • Histogram — Summarize one measure in deterministic numeric bins.
  • Strip and dot plot — Show the distribution of individual values along one axis.
  • ECDF — Show the cumulative share of observations at or below each value.
  • Beeswarm — Show individual observations without overlapping neighboring points.

Charts overview · Installation · Data & Configuration