Fork of Pathetic Bar Chart
✓ Published1🌍 Public
This example visualizes the top 10 most populous countries as a bar chart, with each country’s bar length proportional to its 2020 population from the United Nations World Population Prospects 2019 dataset. The chart uses React with hooks (`useState`, `useEffect`, `useCallback`) to fetch CSV data via `d3.csv`, then renders SVG rectangles positioned using `d3.scaleBand` for the y-axis and `d3.scaleLinear` for the x-axis. The visualization intentionally omits axes and labels, making it a "pathetic" bar chart. The code loads React and D3 v5 from CDNs and renders within a fixed 960×500 SVG.
AI-generated descriptionA program that shows the top 10 most populous countries as a pathetic bar chart with no axes.
MIT Licensed