Customizing Axes
This bar chart displays the top 10 most populous countries in 2018 using population estimates from the United Nations World Population Prospects, with the data loaded from a local CSV file. The example focuses on customizing D3 axes: the bottom x-axis uses `scaleLinear` with a tick format that converts billions to "B" via `format('.3s')` and `.replace('G', 'B')`, while the left y-axis uses `scaleBand`. Custom styling includes removed domain lines, tick lines styled via `axisBottom` and `axisLeft`, and axis labels and title added as SVG text elements.
AI-generated descriptionThis 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.