Skip to main content
100%

Fork of Making a Bar Chart

✓ Published0🌍 Public
Ggaowxx@qq.com
Last edited Dec 11, 2024
Created on Dec 11, 2024
Forked from Making a Bar Chart

This example shows a horizontal bar chart of population figures for ten countries, with each bar’s length proportional to its value and country names on the y-axis. The chart uses D3 v5’s `csv`, `scaleLinear`, and `scaleBand` to map the data, along with `axisLeft` and `axisBottom` for labeled scales. Bars are rendered as SVG `rect` elements, colored steelblue via CSS, with margins set around a 960×500 viewport. The data comes from a CSV file listing country and population in thousands.

AI-generated description
MIT Licensed

Similar vizzes