Skip to main content
100%

Population

✓ Published0🌍 Public
HHaileabGH
Last edited Dec 7, 2021
Created on Dec 7, 2021
Forked from Stylized Bar Chart

This visualization displays the ten most populous countries as horizontal bars, sorted by population size. The chart uses React to render SVG elements, with D3’s `scaleBand` and `scaleLinear` handling the axis scales and layout. Data comes from the United Nations World Population Prospects 2019 dataset, loaded via D3’s `csv` method and formatted with `d3.format`. Each bar includes a tooltip showing the population value. The code also defines custom `AxisBottom` and `AxisLeft` components to generate tick marks and labels, with styling applied through CSS classes.

AI-generated description

A program that shows the top 10 most populous countries as a bar chart.

Data: United Nations World Population Prospects 2019.

MIT Licensed

Similar vizzes