Charts

Ridgeline plot

Arrange density plots in a visually striking series that resembles a mountain range.

What is a ridgeline plot?

A ridgeline plot, sometimes called a joyplot, displays the distribution of a numeric variable across multiple categories. It works by stacking individual density plots vertically, typically with some overlap to conserve space. This arrangement creates a striking visual effect resembling a series of mountain ranges, where each "ridge" represents the distribution for a different group. Ridgeline plots excel at quickly showing trends, shifts, or changes in distributions across many categories, making it easy to spot patterns that might be harder to discern in separate multiple plots.

Dive into these docs to learn all about the density curves that shape the ridges of a ridgeline plot
Default ridgeline plot
Stack density plots to conserve space and highlight differences between groups.
Ridgeline plot displaying three overlapping density curves, each representing normally distributed data. The curves are arranged vertically in descending order based on their means.

Overlap

The ridges in a ridgeline plot are typically overlapped. This overlapping allows for the efficient use of space, while simultaneously making it easier to compare shapes, means, shifts, and differences between categories.

Graphmatik allows you to customize the degree of overlap with a simply swipe of a slider.
Easily sort ridges
To improve clarity and simplify comparisons, sort your data in ascending or descending order based on the mean of each distribution.
Ridgeline plot displaying six overlapping density curves. The curves are unsorted, appearing disorganized and making it difficult to discern trends or patterns within the data.
Ridgeline plot of six overlapping density curves, sorted vertically in descending order by mean. This arrangement makes it easier to compare the distributions with each other.

Chart properties

PropDefaultDescription
sortnone
none
The ridges are arranged in insertion order.
ascending
The ridges are arranged by mean value from the smallest to largest.
descending
The ridges are arranged by mean value from the largest to smallest.
overlapvalue
slider
Controls the degree of overlap between the series of ridges.
kernelgaussian
gaussian
Applies a gaussian (or bell-shaped) weighting function centered at each data point.
epanechnikov
Applies a parabolic-shaped weighting function, optimal for minimizing mean squared error.
bandwidthSilverman's rule
Silverman's rule
A widely used rule of thumb, assumes approximately normal data, but performs reasonably well for other distributions.
Scott's rule
Another normal reference rule, similar to Silverman's, that calculates the optimal bandwidth assuming a normal distribution. It is typically marginally wider than Silverman's rule of thumb.
manual
Adjust the bandwidth manually.