🌍 Public
Viewing a saved revision (read-only)
c7c61d6dd9984cb686008f0cdfe08a47
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