Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Activity6_Task1

Public visualization

Viewing a saved revision (read-only)

0210316b5b75442f9a9c273952670f1e

Activity6_Task1

0 stars1🌍 Public
SShiva Sai Reddy
Last edited Oct 25, 2024
Created on Oct 24, 2024
Forked from Hello VizHub

This horizontal bar chart displays the 2020 populations of the top 30 countries, arranged from largest to smallest. The visualization uses React and D3 v5 to render scalable vector graphics (SVG) directly within a React component. Data is loaded from a CSV file via D3’s `csv` function, with population values parsed and formatted using `d3.format`. Axis components generate SVG line and text elements, while rectangle marks include native SVG tooltips to reveal precise population figures 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.