Skip to main content
100%

Making a bar chart

✓ Published0🌍 Public
RRamziCharradi
Last edited Dec 2, 2019
Created on Nov 29, 2019
Forked from Customizing Axes

A horizontal bar chart displays population counts for ten countries, sorted by descending value. The visualization uses D3.js v5 with SVG rendering, loading data from a CSV file and scaling populations linearly on the x-axis while using band scales for country categories on the y-axis. Axes are generated with d3.axisLeft and d3.axisBottom, and bars are appended as SVG rectangles with heights derived from the band scale’s bandwidth.

AI-generated description

An example of a simple bar char.

MIT Licensed

Similar vizzes