Skip to main content
100%

United Nations Bar Chart with SVG

✓ Published9🌍 Public
RRichardPearce60
Last edited Feb 13, 2022
Created on Feb 13, 2022

This example visualizes the top 10 most populous countries in 2020 using a horizontal bar chart rendered with React and D3 v7. It loads UN population data from a CSV file, scales the bars with d3.scaleLinear, and positions country labels using d3.scaleBand. Each bar is annotated with a flag image fetched from an external SVG collection, placed at the end of the bar with xlink:href. Axes and gridlines are generated via d3’s scale.ticks(), and the chart updates asynchronously after data loading.

AI-generated description
MIT Licensed

Similar vizzes