Scatter chart — discrete data points on a 2D Cartesian plane.
Supports multiple series with automatic color assignment, and optional line or area overlays connecting each series' points.
A named series of (x, y) scatter points.
Optional overlay drawn on top of scatter points.
NoOverlay — points only (default).WithLine — connects each series' points with a line (sorted by x).WithArea — fills the region under each series' points.Create a scatter chart from multiple named series.
Create a single-series scatter chart from (x, y) pairs.
Set chart width in pixels. Default: 500.
Set chart height in pixels. Default: 300.
Apply a Theme.
Set the x-axis label.
Set the y-axis label.
Set the chart title.
Set the radius of scatter points in pixels. Default: 5.
Add a line or area overlay connecting each series' points. Default: NoOverlay.
-- Scatter + connecting line (sorted by x):
Scatter.fromSeries series
|> Scatter.withOverlay Scatter.WithLine
|> Scatter.toSvg
-- Scatter + filled area:
Scatter.fromSeries series
|> Scatter.withOverlay Scatter.WithArea
|> Scatter.toSvgShow a skeleton placeholder instead of the chart while data is loading.
Enable SVG <title> tooltips on each point. Default: False.
When enabled, hovering over a scatter point shows a browser-native tooltip
with the x and y coordinates (e.g. "(3.5, 72.0)"). No ports or state required.
Render to Html msg.
An opaque scatter chart configuration.