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
Rrigt
Last edited Oct 17, 2018
Created on Oct 17, 2018

This example visualizes population over time by region, displaying multiple trend lines across a Cartesian coordinate system. The chart uses D3’s `nest` and `line` with `curveBasis` to structure and smooth the data, while `scaleTime`, `scaleLinear`, and `scaleOrdinal` manage the axes and color encoding. A color legend, generated by a custom `colorLegend` function, identifies each region. The data comes from UN population estimates and medium-variant projections, processed through a custom `melt` function that reshapes the dataset.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed