Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Making a Bar Chart

Public visualization

Making a Bar Chart

0 stars0🌍 Public
BBatkhongor Chagnaa
Last edited May 7, 2022
Created on May 7, 2022

This bar chart displays population estimates for five countries, with horizontal bars sorted by country name and scaled proportionally to population values loaded from a CSV file. The visualization uses D3 v5’s `scaleLinear`, `scaleBand`, `axisLeft`, and `axisBottom` to map data to SVG rectangles, while the `csv` method parses the data and converts population strings to numbers. The chart populates a static SVG canvas with a steelblue fill and clear axis labels.

AI-generated description

Demonstrates fundamental DOM manipulation using D3.js by making a smiley face whose eyebrows move.

Comments

Sign in to join the discussion.

MIT Licensed