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 stars0🌍 Public
Jjbruzzo
Last edited May 3, 2019
Created on May 2, 2019

This example shows population trends over time by region, with each region represented as a separate colored line. The visualization uses D3 v5 to load and process UN population estimates from CSV files, then melts the data into a tidy format using custom logic. Multiple lines are rendered with d3.line and curveBasis, while an ordinal color scale with a legend distinguishes regions. Axes are drawn using d3.axisBottom and d3.axisLeft, and the chart updates based on nested data sorted by final population values.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed