Skip to main content
100%

Customizing Axes

✓ Published0🌍 Public
VVivian Peng
Last edited Sep 28, 2020
Created on Sep 28, 2020
Forked from Customizing Axes

This visualization displays the population of the top 10 most populous countries using a horizontal bar chart, with data sourced from the 2018 United Nations World Population Prospects. The example demonstrates how to customize D3 axes in an SVG rendering, building on a simpler bar chart tutorial. It uses D3 v5 APIs including `scaleLinear`, `scaleBand`, `axisLeft`, and `axisBottom` to position bars and style tick marks, labels, and axis lines via CSS. The chart reads population data from a CSV file and scales the values by 1,000.

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. It also demonstrates customization of D3 axes.

See also the first bar chart visualization that this one builds on: Making a Bar Chart.

MIT Licensed

Similar vizzes