Skip to main content
100%

Activity6_Task1

✓ Published0🌍 Public
Rrahul.bonu524@gmail.com
Last edited Oct 19, 2024
Created on Oct 18, 2024
Forked from Hello VizHub

This example shows a horizontal bar chart of population data for 30 countries in 2020, with each bar labeled by country name and sized proportionally to its population value. The visualization is rendered as an SVG using React components, with D3’s `scaleBand` and `scaleLinear` handling the axis scales and D3’s `format` function converting tick labels to abbreviated units like “B” for billions. Data is loaded asynchronously from a CSV file using D3’s `csv` method, and the chart includes interactive tooltips via SVG `<title>` elements that display the formatted population on hover.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.
MIT Licensed

Similar vizzes