Fork of Pathetic Bar Chart
✓ Published0🌍 Public
This example shows the top 10 most populous countries as a horizontal bar chart with labeled bars but no axes, using React to render SVG elements. The code loads United Nations World Population Prospects 2019 data via d3.csv, then applies d3.scaleLinear and d3.scaleBand to map population values and country names to pixel coordinates. It manually draws gridlines and tick labels using d3.scaleLinear ticks, while omitting axis components. Bars are rendered as SVG rectangles whose widths reflect each country’s 2020 population estimate, with country names positioned along the y-axis.
AI-generated descriptionA program that shows the top 10 most populous countries as a pathetic bar chart with no axes.
MIT Licensed