🌍 Public
Viewing a saved revision (read-only)
1d50584449a64f81adf98987de43bf38
Melting Data for Multiple Lines
This example shows population trends over time by region, with multiple colored lines in an SVG chart. The data is processed by melting wide-format UN population estimates into tidy long-form rows using `range` and `timeParse`. The visualization uses `scaleTime`, `scaleLinear`, `scaleOrdinal`, `line` with `curveBasis`, `nest`, and `axisLeft`/`axisBottom`. A custom color legend displays categorical regions, and lines are sorted by their final population value using `descending`.
AI-generated description