🌍 Public
Viewing a saved revision (read-only)
91e7043e2ec64f14b5483986f55210e8
Population Line Chart
This visualization displays population figures for the top 10 countries in 2020 using a horizontal bar chart. The chart maps country names to a `d3.scaleBand` y-axis and population values to a `d3.scaleLinear` x-axis, rendering each bar as an SVG `rect` element. Data is loaded asynchronously via `d3.csv` from a UN Population dataset, with React state managing the loaded data through `useState` and `useEffect`. The visualization is built using React 18 and D3 v7, rendered entirely as SVG within a fixed 960×500 viewport.
AI-generated descriptionA program that loads in some data using d3 utilities, and uses react state to keep track of the data.