Stylized Bar Chart
✓ Published1🌍 Public
This example displays the top 10 most populous countries as horizontal bars, with a fixed-width SVG layout and a loading state. It uses React with d3.scaleBand for the y-axis and d3.scaleLinear for the x-axis, while d3.format abbreviates population values (e.g., “1.4B”). The data is loaded via d3.csv from the UN World Population Prospects 2019 dataset, sorted and sliced to the top 10. Axes are custom SVG components, and each bar has a native <title> tooltip.
AI-generated descriptionA program that shows the top 10 most populous countries as a pathetic bar chart with no axes.
MIT Licensed