stat: "summary_bin"

Bin continuous x, then summarize y in each bin (mean ± se by default). Publishes y, ymin, ymax for binned summaries.

Usage

import { GGPlot, GeomPoint } from "@ggsvelte/svelte";

<GGPlot data={rows} aes={{ x: "x", y: "y" }}>
  <GeomPoint stat="summary_bin" />
</GGPlot>
{
  "geom": "point",
  "stat": "summary_bin"
}

Generated columns (after_stat)

Resolve these with channel objects such as { stat: "y" } in aes.

  • y
  • ymin
  • ymax

Default for geoms

No geom uses this as its default stat. Set it explicitly when needed.

Compatible geoms

Examples

← All stats · Geoms · Statistics and positions