Skip to main content
100%

Selecting a Year on a Line Chart

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

This line chart displays global population trends for regions from 1950 to 2100, with a movable vertical line that lets the user select a specific year. The chart highlights population values for that chosen year via circles on each regional line, with a color legend identifying each region. Built with D3 v5, the visualization uses `scaleTime`, `scaleLinear`, `axisBottom`, `axisLeft`, and `line` with `curveBasis` to render the SVG chart. Data comes from UN population estimates and medium variant projections, loaded via `csv` and processed through `nest` and `melt` functions. Hover interactions are handled by the `mouse` callback on an invisible rectangle.

AI-generated description
MIT Licensed

Similar vizzes