Q1-2
✓ Published0🌍 Public
This example displays a horizontal bar chart comparing the populations of 20 countries in 2010, sorted by country name along the vertical axis. The chart uses a linear scale for population values and a band scale for countries, with green bars that include tooltips showing the formatted population in billions. Built with React and D3 v5, the visualization loads CSV data via `d3.csv`, renders SVG elements through React components, and formats axis ticks using `d3.format`. The code demonstrates local ES6 module imports and reusable axis and mark 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