Activity6_Que1_2
✓ Published0🌍 Public
This example presents a horizontal bar chart comparing the 2010 populations of twenty countries, rendered as SVG within a React application. The data is loaded from a CSV file using `d3.csv`, with bars drawn as `rect` elements whose widths are scaled by `d3.scaleLinear`. Axes are generated with `d3.scaleBand` and custom components, while tick labels use `d3.format` to abbreviate large numbers. Hovering over a bar reveals the precise population value via a native SVG `<title>` tooltip.
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