Skip to content
Plotly templates

Grouped Box Plot (Plotly)

Compare distributions across groups with box-and-whisker plots.

Template previewPlotly
Rendering…

Make it your own.

{
  "data": [
    {"type": "box", "name": "Control", "y": [22, 24, 25, 25, 26, 27, 28, 30, 31, 40], "boxpoints": "outliers"},
    {"type": "box", "name": "Treatment A", "y": [18, 19, 20, 21, 21, 22, 23, 24, 25, 27]},
    {"type": "box", "name": "Treatment B", "y": [15, 16, 17, 17, 18, 19, 20, 21, 22, 30]}
  ],
  "layout": {
    "title": "Outcome by group",
    "yaxis": {"title": "Score"},
    "showlegend": false
  }
}