🌍 Public
Making a Bar Chart 2019
This example uses D3 v5 to render a horizontal bar chart of 2019 population estimates for the ten most populous countries, sourced from a CSV file. It maps population values to a linear scale for bar widths and country names to a band scale for vertical positioning, drawing SVG rectangles. The chart includes axes generated with `axisLeft` and `axisBottom`, while data loading and scaling use `csv`, `scaleLinear`, `scaleBand`, and `max`.
AI-generated descriptionMIT Licensed
Comments
Sign in to join the discussion.