Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Bar Chart

Public visualization

Viewing a saved revision (read-only)

5cc37415163b40c5a278f2b8f19ba33c

Bar Chart

0 stars0🌍 Public
DDeepak Kapoor
Last edited Aug 2, 2019
Created on Aug 2, 2019

This bar chart displays country population data from a CSV file, rendering each row as a fixed-width rectangle. The code uses D3 v5's `select` and `csv` functions to load the data and append SVG `rect` elements, with population values converted to numbers via `+d.population`. The chart is embedded in a React context and rendered to an SVG canvas using plain JavaScript DOM manipulation.

AI-generated description

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