Skip to main content
100%

Making a Bar Chart

✓ Published1🌍 Public
NNazgulZaki
Last edited Apr 28, 2019
Created on Apr 28, 2019
Forked from Making a Bar Chart

This example displays a horizontal bar chart comparing the 2018 populations of the top ten most populous countries, with data sourced from the United Nations’ World Population Prospects 2017. The visualization uses D3 v5’s `scaleLinear` and `scaleBand` to map population values and country names, appending SVG rectangles for each bar. It demonstrates the classic D3 workflow of loading CSV data, converting population strings to numbers, and using `axisLeft` and `axisBottom` to render the chart’s axes.

AI-generated description

This bar chart shows population of the top 10 most populous countries. The data comes from the year 2018 estimate in United Nations: World Population Prospects 2017.

MIT Licensed

Similar vizzes