Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Melting Data for Multiple Lines

Public visualization

Melting Data for Multiple Lines

0 stars2🌍 Public
CChenluWang96
Last edited Mar 10, 2020
Created on Mar 10, 2020

This visualization shows population trends over time for global regions, with each region represented as a colored line. The chart uses multiple lines to compare regional population growth from 1950 to 2100, with a color legend on the right side. The code processes United Nations population data by melting it into a tidy format, then uses d3.line with curveBasis to generate smooth paths, d3.nest to group by region, and d3.scaleOrdinal with schemeCategory10 for colors. Axes are rendered using d3.axisLeft and d3.axisBottom, with SVG rendering and custom tick formatting for population values.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed