🌍 Public
Viewing a saved revision (read-only)
de3782fc8c014247bc5282f1c3cf0efa
Selecting a Year on a Line Chart
This visualization displays population trends over time for global regions, with a vertical line marking the currently selected year. Users can hover over the chart to change the selection, which updates the highlighted year. The chart uses D3 v5 with SVG rendering, employing scales like `scaleTime` and `scaleLinear` for axes, and `d3.line` with `curveBasis` for smooth paths. Data comes from UN population estimates and medium variant projections, processed via `d3.csv` and `d3.nest`. A custom color legend shows region names, and the selection uses mouse events to update the year.
AI-generated description