🌍 Public
Viewing a saved revision (read-only)
134fcad98d9f413dac32e60e038a2239
Activity 6_Question 2
This example shows a horizontal bar chart of population figures for 20 countries in 2010, with each bar’s length encoded by population value and countries labeled on the y-axis. The visualization is built with React and D3 v5, using `scaleBand` and `scaleLinear` for positioning, and custom `AxisBottom` and `AxisLeft` components to render tick marks and labels. Data is loaded via `d3.csv` from a GitHub-hosted CSV file, and bars are drawn as SVG `<rect>` elements with a tooltip using the native `<title>` element.
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.