stat: "density"

1D Gaussian kernel density estimate along x. Publishes density, count, scaled, and ndensity; default for geom_density.

Usage

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

<GGPlot data={rows} aes={{ x: "x" }}>
  <GeomDensity stat="density" />
</GGPlot>
{
  "geom": "density",
  "stat": "density"
}

Generated columns (after_stat)

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

  • density
  • count
  • scaled
  • ndensity

Default for geoms

Compatible geoms

Examples

← All stats · Geoms · Statistics and positions