Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Selecting the Year on a Line Chart

Public visualization

Selecting the Year on a Line Chart

0 stars0🌍 Public
MMuhammad Jarir Kanji
Last edited Dec 20, 2020
Created on Dec 20, 2020

This line chart displays world population trends from 1950 to 2100, with each country shown as a colored line. Users can select a specific year by moving the mouse across the chart, which updates a vertical black line to the corresponding time point. The visualization uses D3.js with d3.csv for data loading, d3.nest for grouping data by country, and d3.scaleTime/Linear for axes. A d3.axisBottom and d3.axisLeft render the gridlines, while the line generator uses curveBasis for smoothing. Population data comes from UN estimates and projections.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed