Fork of Activity 7
✓ Published0🌍 Public
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 descriptionMIT Licensed