Examples · Ridgeline

Ridgeline plot examples

A typical support reply takes a few minutes, but a busy weekday can leave a long tail of waits. These fictional readings show both patterns. Each ridge estimates the distribution for one weekday; its thin line inside the ridge locates the median.

When to use it

  • Compare the shape and spread of measurements across several groups
  • Look for a wider tail or a second cluster that a median would hide

Not the right shape?

For a few observations, use a dot plot. Use a histogram when exact bin counts matter. If you only need to compare medians, calculate them and use a bar or dot plot instead.


Real-world examples

Daily temperatures

Illustrative temperatures in degrees Celsius. Winter spans both sides of zero.

Open in maker with this data

View the spec
{
  "type": "ridgeline",
  "theme": "editorial",
  "title": "How the season changes the spread",
  "source": "Illustrative data · degrees Celsius",
  "data": {
    "labels": [],
    "series": [],
    "groups": [
      {
        "id": "g0",
        "label": "January",
        "observations": [
          -8,
          -5,
          -3,
          -2,
          -1,
          0,
          1,
          2,
          3,
          4,
          5,
          7
        ]
      },
      {
        "id": "g1",
        "label": "April",
        "observations": [
          5,
          7,
          9,
          10,
          12,
          13,
          14,
          15,
          16,
          18,
          19,
          22
        ]
      },
      {
        "id": "g2",
        "label": "July",
        "observations": [
          19,
          21,
          23,
          24,
          25,
          26,
          27,
          28,
          29,
          30,
          32,
          35
        ]
      }
    ]
  }
}

Build durations

Illustrative build times. One branch has a slow cluster even though most builds finish quickly.

Open in maker with this data

View the spec
{
  "type": "ridgeline",
  "theme": "editorial",
  "title": "Which branch has the long build tail?",
  "source": "Illustrative data · seconds",
  "data": {
    "labels": [],
    "series": [],
    "groups": [
      {
        "id": "g0",
        "label": "Main",
        "observations": [
          22,
          24,
          25,
          26,
          27,
          28,
          29,
          30,
          31,
          32,
          33,
          35
        ]
      },
      {
        "id": "g1",
        "label": "Search",
        "observations": [
          20,
          21,
          22,
          24,
          25,
          26,
          42,
          44,
          46,
          48,
          50,
          52
        ]
      },
      {
        "id": "g2",
        "label": "Reports",
        "observations": [
          30,
          31,
          32,
          34,
          35,
          36,
          38,
          40,
          43,
          46,
          50,
          55
        ]
      }
    ]
  }
}
Open this chart in a maker Ridgeline plot maker from scratch


Questions people ask

How is each ridge calculated?

A Gaussian kernel density estimate uses the raw readings. All groups share a bandwidth chosen by Silverman's rule on the within-group deviations. The curve stops at the overall data range plus four bandwidths on each side.

What does ridge height mean?

The default height uses a shared density scale. Choosing each group's own peak makes shapes easier to inspect but removes height comparisons; the chart prints a notice when that option is active.

What happens with missing or sparse data?

Null readings are counted as missing and excluded from density calculations. Groups with fewer than five known readings or constant values show dots. Empty groups remain visible with a No data label.