Skip to main content
100%

Fork of Activity 7

✓ Published0🌍 Public
Vvineelaramulapalli32
Last edited Jul 16, 2023
Created on Jul 16, 2023
Forked from Activity 7

This example shows a horizontal bar chart of the top 20 countries by 2020 population, using a React-based SVG rendering. It maps the `Population` values to bar widths and `Country` names along the left axis, formatting population figures with D3’s `format('.2s')` to display billions. The code loads CSV data via `d3.csv`, then scales the bars using `scaleBand` and `scaleLinear`. Axis components are built manually with React, and tooltips are provided through SVG `<title>` elements. The chart’s styling includes blue tick lines, green bars, and a Poppins font.

AI-generated description

A demonstration of how to start using D3 version 6.

MIT Licensed

Similar vizzes