This interactive bubble chart displays the relationship between fertility rate and life expectancy for ten countries in 2010, with bubble size representing population and color encoding geographical region. Hovering over a bubble reveals a tooltip with the country name, region, and population. The visualization uses D3 v7's `scaleLinear` for axes, `scaleOrdinal` with `schemeCategory10` for regional coloring, and `axisBottom`/`axisLeft` for tick marks, loading data from a local CSV file into an SVG rendered through D3's selection API.
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
Comments
Sign in to join the discussion.