Activity6_Question1.2
✓ Published0🌍 Public
This example shows a horizontal bar chart of the top 20 countries by 2010 population, using SVG rectangles positioned by D3 scaleBand and scaleLinear. React components render the axis and marks, with the bottom axis formatting values using D3’s format function to convert abbreviations like “G” to “B”. Data loads asynchronously via d3.csv from a GitHub raw URL, and tooltips display formatted values through the SVG title element. The chart uses Poppins font styling and a green mark fill from the included CSS.
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