Skip to main content
100%

Making a bar chart with D3.js

✓ Published1🌍 Public
Ggorfoula
Last edited Jul 13, 2020
Created on Jul 13, 2020

This example shows a horizontal bar chart of population per country, with country names labeled along the vertical axis and population values on the horizontal axis. The chart renders population data for eleven countries, sourced from WorldoMeter, as SVG rectangles using D3.js v5 within a React framework. It uses `d3.csv` to load the data, `scaleLinear` and `scaleBand` for scaling, `axisLeft` and `axisBottom` for ticks, and `select` to append elements to the SVG container.

AI-generated description

A bare minimum HTML page.

See also React Starter.

Bar chart of population per country taken from the WorldoMeter.

MIT Licensed

Similar vizzes