Activity-8_Question-1.2
✓ Published0🌍 Public
This example shows a horizontal bar chart comparing the populations of twenty countries in 2010, with the bars colored green and axes styled with blue tick lines. It uses React to manage the component state and render the SVG, while D3 v5 provides the `scaleBand`, `scaleLinear`, `csv`, `max`, and `format` APIs for data loading, scaling, and tick formatting. The data is fetched from a CSV file using `useData`, and local modules `AxisBottom`, `AxisLeft`, and `Marks` implement the chart components.
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