🌍 Public
Viewing a saved revision (read-only)
9efd6a6a65b043dca6cf59348632f27d
Stylized Bar Chart
This example displays the 20 most populous countries in 2020 as a horizontal bar chart, sorted by population size. The visualization uses React to render SVG elements, with D3’s `scaleBand` for the categorical y-axis and `scaleLinear` for the quantitative x-axis. Custom axis components generate ticks and labels, while each bar includes a tooltip via the SVG `<title>` element. Data comes from the United Nations World Population Prospects 2019, loaded as CSV and formatted with D3’s `format` to abbreviate large numbers (e.g., billions).
AI-generated descriptionA program that shows the top 10 most populous countries as a bar chart.