π Public
Customizing Axis
This example displays a bar chart of the top 10 most populous countries using 2018 population estimates from the World Population Prospects 2017 dataset. It emphasizes customized axes, with a bottom axis labeled "Population" and a left axis using abbreviated tick labels (e.g., "1.4B") via `d3.format`. The chart uses `d3.scaleBand` for the x-axis and `d3.scaleLinear` for the y-axis, with grid lines generated by `d3.axisLeft` and `d3.axisBottom`. Data is loaded from a CSV file and rendered as SVG rectangles.
AI-generated descriptionThis bar charts shows population of the top 10 most populous countries. the data comes from the year 2018 estimate in World Population Prospects 2017.
MIT Licensed
Comments
Sign in to join the discussion.