Skip to main content
100%

Fork of Pathetic Bar Chart

✓ Published0🌍 Public
Ssultanmirzapydev
Last edited Aug 23, 2021
Created on Aug 23, 2021
Forked from Pathetic Bar Chart

This example shows the top 10 most populous countries as a set of horizontal bars with no axes, labels, or other chart furniture. Using React hooks like `useState` and `useEffect`, it loads United Nations population data from a CSV via `d3.csv`, then renders the bars as SVG `<rect>` elements. The bar widths are scaled with `d3.scaleLinear`, while the vertical positions use `d3.scaleBand`. The chart updates reactively once the data arrives, displaying a simple loading message beforehand.

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