Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Pathetic Bar Chart

Public visualization

Viewing a saved revision (read-only)

4e20d1c3460e47489dca37353db1625b

Pathetic Bar Chart

0 stars1🌍 Public
RRajat Dangat
Last edited Mar 26, 2021
Created on Mar 26, 2021

This example displays the top 10 most populous countries as horizontal bars, using a United Nations population dataset loaded via `d3.csv`. The bars render in SVG, with `d3.scaleBand` positioning each country along the y-axis and `d3.scaleLinear` mapping population values to bar widths on the x-axis. React manages the data state and renders each rectangle, while D3 handles the scaling and data parsing.

AI-generated description

A program that shows the top 10 most populous countries as a bar chart.