🌍 Public
Viewing a saved revision (read-only)
e85de170db95466a8ef1821a93085572
Fork of activity 6_Task 1
This example shows a horizontal bar chart of 2020 population estimates for 30 countries, ranked by country name along the y-axis. The chart uses React to render SVG marks, with D3 v5’s `scaleBand` and `scaleLinear` to position bars and axes, and `format` to abbreviate population values (e.g., “B” for billions). Data is loaded asynchronously via `d3.csv` from a GitHub Gist, with raw population values multiplied by 1,000. Axis components (`AxisBottom`, `AxisLeft`) and `Marks` are built as React components, and each bar includes a native SVG `<title>` tooltip.
AI-generated descriptionA demonstration of how to start using D3 version 6.