Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Activity 7

Public visualization

Fork of Activity 7

0 stars0🌍 Public
Nnissisharon61@gmail.com
Last edited Mar 30, 2025
Created on Mar 30, 2025
Forked from Activity 7

This example shows a horizontal bar chart ranking 30 countries by their 2020 population, with each bar labeled with its country name and a tooltip displaying the formatted population value on hover. The visualization uses React components to render SVG elements, with d3.scaleBand and d3.scaleLinear handling the axes and data mapping. Data is loaded asynchronously via d3.csv from a GitHub-hosted CSV file, and axis ticks are formatted using d3.format to abbreviate large numbers (e.g., 'B' for billions). The chart features custom axis components that generate tick marks and labels, with styling applied through CSS selectors.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed