Skip to main content
100%

D3 init

✓ Published0🌍 Public
PPaweł Cesar Sanjuan Szklarz
Last edited Jul 2, 2020
Created on Jun 30, 2020
Forked from HTML Starter

A minimal bar chart maps country populations from a CSV file to SVG rectangles. The code loads `data.csv` using `d3.csv`, multiplies each population value by 1000, and renders horizontal bars with `d3.scaleLinear` for the x-axis and `d3.scaleBand` for the y-axis. It appends rectangles to an SVG element selected via `d3.select`, with dimensions derived from the scales and a fixed margin offset. The example demonstrates a basic D3 v5 data-joining workflow with asynchronous data loading.

AI-generated description

D3 minimal visualization

MIT Licensed

Similar vizzes