Melting Data for Multiple Lines
✓ Published1🌍 Public
This visualization displays population trends over time for various world regions using multiple lines. The chart combines historical estimates from a 2017 UN dataset with medium-variant projections through 2100, showing each region’s population trajectory in a distinct color. The code uses d3.csv to load data, d3.nest to group by region, d3.line with curveBasis for smooth paths, and d3.scaleTime and d3.scaleLinear for axes. A custom colorLegend component renders the categorical scale, while d3.axisLeft and d3.axisBottom create labeled tick marks.
AI-generated descriptionMIT Licensed