Skip to main content
100%

Pathetic Bar Chart

✓ Published1🌍 Public
CChira Cezara Victoria
Last edited Oct 2, 2021
Created on Oct 2, 2021
Forked from CSS Colors Pie

This example displays a horizontal bar chart of the top ten countries by 2020 population from a UN dataset. The bars are rendered as SVG rectangles without labels or axes, appearing intentionally minimal. The code loads data with `d3.csv`, scales it using `scaleBand` and `scaleLinear`, and renders the chart through React components. The visualization relies on React’s `useState` and `useEffect` hooks to asynchronously fetch and update the data, with D3 version 5 handling the scaling logic.

AI-generated description
MIT Licensed

Similar vizzes