🌍 Public
Viewing a saved revision (read-only)
0623c94f781d4778a5c4763e992cd32c
Making a Bar Chart
This example shows the populations of South American countries as horizontal bars, sorted by country name, with population values formatted in abbreviated units. The bar chart uses D3 v5’s `scaleLinear` for the x-axis and `scaleBand` for the y-axis, with SVG rendering. Axes are generated via `axisLeft` and `axisBottom`, and data is loaded from a CSV file using `d3.csv`. The code removes default axis domain lines and adds custom axis labels and a title.
AI-generated description