Melting data for multiple lines
✓ Published0🌍 Public
This example displays population trends over time for multiple world regions as overlapping curved lines, with a color legend identifying each region and a vertical marker highlighting the year 2018. The visualization uses D3 v5’s `nest()` to group data by region, `scaleTime` and `scaleLinear` for axes, and `line` with `curveBasis` to generate smooth paths. Data is loaded from CSV files via `csv()` and melted from wide to long format, while `axisBottom` and `axisLeft` render the grid and labels.
AI-generated descriptionMIT Licensed