Skip to main content
twblazor
Home
  • Get started
  • Tailwind with Blazor
  • Why twblazor?
  • Theme
  • Class Merge
    • Configuring localization
    • RTL Provider
  • Breadcrumb
  • Card
  • Carousel
  • Collapse
  • Context Menu
  • Drawer
  • Footer
  • Menu
  • Navbar
  • On This Page
  • Separator
  • Sidebar
  • Stepper
  • Tabs
  • Tree List
  • Container
  • Flex
  • Grid
  • Text
  • Link
  • Button
  • Form
    • AutocompleteNew
    • Checkbox
    • Color Picker
    • Date Picker
    • Date Range Picker
    • Datetime Picker
    • Datetime Range Picker
    • File Upload
    • Input GroupNew
    • NumericNew
    • Masked InputNew
    • Radio Button
    • Range SliderNew
    • RatingNew
    • Select
    • Slider
    • Switch
    • Tag InputNew
    • Text EditorNew
    • Textfield
    • Time Picker
    • Time Range Picker
  • Toggle
  • Toggle Group
  • Alert
  • Avatar
  • Badge
  • Chip
  • Empty
  • Icon
  • Popover
  • Progress
  • Skeleton
  • Spinner
  • Tooltip
  • Data Table
  • SpreadsheetNew
  • Column Filter Editor
  • Pagination
  • Pick List
  • Barcode
  • QR Code
  • Calendar
  • Table
  • Attachment
  • Overview
    • Bar
    • Bullet
    • Column
    • Dot Plot
    • Dumbbell
    • Icon
    • Lollipop
    • Radial Bar
    • Range
    • Word Cloud
    • Area
    • Bump
    • Bump Area
    • Candlestick
    • Gantt
    • Horizon
    • Line
    • Slope
    • Small Multiples
    • Stream Graph
    • Funnel
    • Gauge
    • Marimekko
    • Nightingale
    • Pie
    • Treemap
    • Waffle
    • Waterfall
    • Circular Treemap
    • Convex Treemap
    • Dendrogram
    • Sunburst
    • Barcode
    • Beeswarm
    • Box Plot
    • Density Plot
    • Histogram
    • Radial Histogram
    • Ridgeline
    • Strip Plot
    • Violin Plot
    • Categorical Scatter
    • Contour
    • Hexagonal Binning
    • Quadrant
    • Scatter
    • Heatmap
    • Matrix
    • Parallel Coordinates
    • Radar
    • Arc Diagram
    • Chord Diagram
    • Flowchart
    • Network Diagram
    • Sankey
    • Euler Diagram
    • Venn Diagram
  • Bubble
  • Marker
  • Message
  • Dialog Service
  • Toast Service
API DocumentationAI Agents & Skills
Home Get Started

Charts

TwRidgelinePlotChart

TwRidgelinePlotChart is a Blazor ridgeline plot that gives each group its own row and density curve, for comparing many distributions.

Last updated 23 October 2026

Basic usage

TwRidgelinePlotChart draws one density curve per ChartSample, each on its own row with its name on the axis. Where a density plot overlays its curves, a ridgeline keeps them apart, so it copes with many more groups.
Delivery time by monthDays from order to delivery
JanuaryFebruaryMarch
JanuaryFebruaryMarch
JanuaryCount 11Minimum 3Lower quartile 4.5Median 5Upper quartile 6.5Maximum 9
FebruaryCount 10Minimum 2Lower quartile 3.25Median 4Upper quartile 5Maximum 7
MarchCount 10Minimum 1Lower quartile 2Median 3Upper quartile 3.75Maximum 5
0246810
RAZOR
<TwChart Title="Delivery time by month" Description="Days from order to delivery">
    <TwRidgelinePlotChart Samples="@_deliveries" />
</TwChart>
CSHARP
@code {
    private readonly ChartSample[] _deliveries =
    [
        new("January", [3, 4, 4, 5, 5, 5, 6, 6, 7, 8, 9]),
        new("February", [2, 3, 3, 4, 4, 4, 5, 5, 6, 7]),
        new("March", [1, 2, 2, 2, 3, 3, 3, 4, 4, 5])
    ];
}

Many groups

Order the groups so a drift is easy to follow. Here the daily temperature shifts up and back down across the year. A larger Height gives each ridge more room.
Daily high temperatureDegrees Celsius, by month
JanMarMayJulSepNov
JanMarMayJulSepNov
JanCount 10Minimum 4°Lower quartile 6°Median 8°Upper quartile 9°Maximum 11°
MarCount 10Minimum 7°Lower quartile 9°Median 11°Upper quartile 13°Maximum 15°
MayCount 10Minimum 13°Lower quartile 15°Median 17°Upper quartile 19°Maximum 22°
JulCount 10Minimum 18°Lower quartile 21°Median 23°Upper quartile 25°Maximum 30°
SepCount 10Minimum 14°Lower quartile 17°Median 19°Upper quartile 21°Maximum 24°
NovCount 10Minimum 6°Lower quartile 8°Median 10°Upper quartile 12°Maximum 14°
0°10°20°30°
RAZOR
<TwChart Title="Daily high temperature" Description="Degrees Celsius, by month">
    <TwRidgelinePlotChart Samples="@_temperatures" LabelHeader="Month" ValueFormat="0°" Height="ChartHeight.Large" />
</TwChart>
CSHARP
@code {
    private readonly ChartSample[] _temperatures =
    [
        new("Jan", [4, 5, 6, 6, 7, 8, 8, 9, 10, 11]),
        new("Mar", [7, 8, 9, 10, 10, 11, 12, 13, 14, 15]),
        new("May", [13, 14, 15, 16, 17, 17, 18, 19, 20, 22]),
        new("Jul", [18, 20, 21, 22, 23, 23, 24, 25, 27, 30]),
        new("Sep", [14, 16, 17, 18, 18, 19, 20, 21, 22, 24]),
        new("Nov", [6, 7, 8, 9, 9, 10, 11, 12, 13, 14])
    ];
}

Side by side

Groups are listed top to bottom by default. Set Horizontal to false to stand the ridges side by side with values running up the plot.
Delivery time by month
0246810
0246810
JanuaryCount 11Minimum 3Lower quartile 4.5Median 5Upper quartile 6.5Maximum 9
FebruaryCount 10Minimum 2Lower quartile 3.25Median 4Upper quartile 5Maximum 7
MarchCount 10Minimum 1Lower quartile 2Median 3Upper quartile 3.75Maximum 5
JanuaryFebruaryMarch
RAZOR
<TwChart Title="Delivery time by month">
    <TwRidgelinePlotChart Samples="@_deliveries" Horizontal="false" />
</TwChart>

When to use

Use a ridgeline plot to compare the shape of many distributions. Each ridge is scaled to the height of its own row, so compare where the ridges sit and how wide they are, not how tall. For two or three groups, TwDensityPlotChart puts them on one scale.

Summary

Tooltips and the table view give the count, minimum, lower quartile, median, upper quartile and maximum of each group.

Shared features

The legend, tooltips, keyboard navigation, table view, value formatting, height and empty state work the same on every chart. See TwChart for those options.

Keyboard navigation

The plot is a single Tab stop. Each data point is announced with its series and value as focus reaches it, and the table view presents the same data without the plot.
Key What it does
Tab Moves focus into the plot, onto the data point last visited.
Arrow Right or Arrow Down Moves to the next data point.
Arrow Left or Arrow Up Moves to the previous data point.
Home or End Moves to the first or last data point.
Escape Hides the tooltip of the focused data point.
Enter or Space On a legend item: shows or hides that series. On the table button: switches between the chart and its data table.

On this page

  • Basic usage
  • Many groups
  • Side by side
  • When to use
  • Summary
  • Shared features
  • Keyboard navigation
twblazor

The Tailwind CSS component library for Blazor. Accessible, themeable and MIT licensed.

Discord (opens in a new tab) GitHub(opens in a new tab)

Get started

  • Install guide
  • Theming
  • Class merging
  • Localization

Guides

  • Tailwind CSS with Blazor
  • Why twblazor?
  • Right to left
  • AI agents and skills

Resources

  • API documentation (opens in a new tab)
  • llms.txt (opens in a new tab)
  • MIT License (opens in a new tab)

Community

  • Contributing (opens in a new tab)
  • Code of conduct (opens in a new tab)
  • Report an issue (opens in a new tab)

twblazor is and always will be free and open source.

An unhandled error has occurred. Reload