🌍 Public
Viewing a saved revision (read-only)
768d99467c2b48e7871d7107780c496f
Making a Bar Chart
This example shows a horizontal bar chart of the ten most populous countries, with country names on the y-axis and population on the x-axis. The bars are rendered as SVG rectangles, filled with steelblue. The code uses d3.csv to load the data, d3.scaleLinear and d3.scaleBand to map values to coordinates, and d3.axisLeft and d3.axisBottom to draw the axes. The population values are parsed and multiplied by 1,000.
AI-generated description