Skip to main content
100%

Fork of Pathetic Bar Chart

✓ Published0🌍 Public
Bbencooper6851
Last edited Mar 18, 2021
Created on Mar 18, 2021
Forked from Pathetic Bar Chart

This example renders a bar chart of the top 10 most populous countries using React and D3 v5, with bars drawn as SVG rectangles via the `scaleBand` and `scaleLinear` scales. The chart intentionally omits axes and labels, presenting only the raw data values loaded from a CSV file sourced from the United Nations World Population Prospects 2019. Data is fetched asynchronously with `d3.csv` and stored in React state, triggering a re-render once loaded. The bars are positioned using the band scale’s `yScale` and sized with the linear scale’s `xScale`, with no interactive elements or transitions.

AI-generated description

A program that shows the top 10 most populous countries as a pathetic bar chart with no axes.

Data: United Nations World Population Prospects 2019.

MIT Licensed

Similar vizzes