Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

D3 Prac

Public visualization

Viewing a saved revision (read-only)

d6612e0260dd44d5b9ef3fad278f780d

D3 Prac

0 stars0🌍 Public
Nnancyho629
Last edited Jan 6, 2022
Created on Jan 6, 2022
Forked from Pathetic Bar Chart

This example displays the top 10 most populous countries as a bar chart with no axes or labels, using rectangles whose widths encode population values. The code loads United Nations World Population Prospects 2019 data via `d3.csv`, processes it with a custom row function, and renders SVG bars using React state and hooks. It employs `d3.scaleBand` for vertical positioning and `d3.scaleLinear` for horizontal scaling, all within a React component that manages data loading through `useEffect`.

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.