Skip to main content
100%

Making a bar chart

✓ Published2🌍 Public
NNadia W.
Last edited May 9, 2020
Created on May 9, 2020
Forked from Customizing Axes

This bar chart shows the populations of the top 10 most populous countries in 2018, based on United Nations estimates. The chart uses vertical bars with a linear scale for population and a band scale for country names. The code imports specific functions from d3 v5—including `csv`, `scaleLinear`, `scaleBand`, `axisLeft`, and `axisBottom`—to load the data and render the SVG elements. Bars are colored steelblue via CSS, and axes are positioned using margins and transforms.

AI-generated description

Making a bar chart

This bar chart shoes 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