Skip to main content
100%

Refactored Bar Chart

✓ Published1🌍 Public
AAndre J Denais
Last edited Nov 9, 2020
Created on Sep 11, 2020

This Refactored Bar Chart displays the top ten countries by population in 2020 using a horizontal bar layout. A React component loads CSV data from a GitHub-hosted UN population dataset, then renders an SVG with d3.scaleBand for the categorical y-axis, d3.scaleLinear for the quantitative x-axis, and separate AxisLeft, AxisBottom, and Marks components for modular chart construction. Each bar’s length encodes population values, with axis ticks and labels generated programmatically from the scales.

AI-generated description

A program for playing with Bar Charts in D3.

MIT Licensed

Similar vizzes