Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Axes with React & D3

Public visualization

Viewing a saved revision (read-only)

1be0c9d03cae4318b88b7636d3bc369c

Axes with React & D3

0 stars0🌍 Public
JJenny
Last edited Mar 8, 2021
Created on Mar 4, 2021

This example shows a horizontal bar chart of the top 10 most populous countries, with labeled axes and tooltips. Using React to construct SVG elements, the code creates bottom and left axes with D3’s `scaleBand` and `scaleLinear`, applies a custom tick formatter for population values, and renders bars as `<rect>` elements with `<title>` tooltips. Data comes from the UN World Population Prospects 2019 CSV.

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.