Skip to main content
100%

Selecting a Year on a Line Chart

✓ Published0🌍 Public
FflexKeks
Last edited Sep 1, 2019
Created on Sep 1, 2019

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
MIT Licensed

Similar vizzes