Activity 6 Question 1.2
✓ Published0🌍 Public
This example displays a horizontal bar chart of 2010 population data for 20 countries, with bars sorted by country name along the y-axis and population values on the x-axis. Using React with D3 v5, it loads CSV data via `d3.csv`, scales the population with `scaleLinear`, and positions bars with `scaleBand`. Tooltips appear on hover via SVG `<title>` elements, while custom `AxisBottom` and `AxisLeft` components render ticks, and axis labels are formatted with `d3.format`.
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