Activity 6 question-2
✓ Published0🌍 Public
This example displays a horizontal bar chart of the top 20 countries by 2010 population, sourced from a CSV file hosted on GitHub. The visualization uses React to render SVG elements, with D3's `scaleBand` and `scaleLinear` defining the chart’s scales. Axes are custom-built components that generate ticks and labels, while each bar includes a native SVG `<title>` element for hover tooltips. Population values are formatted using D3’s `format` utility, abbreviating large numbers to billions.
AI-generated descriptionAn example showing the capabilities of VizHub:
- Loads D3 via UNPKG.
- Demonstrates use of
importfrom"d3". - Demonstrates use of
importfrom local ES6 modules.
MIT Licensed