Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Activity 6_Task 1

Public visualization

Viewing a saved revision (read-only)

352e837fb1c140259f8f0fd529a2af1c

Activity 6_Task 1

0 stars0🌍 Public
SSiddhartha Alwala
Last edited Apr 9, 2024
Created on Apr 9, 2024
Forked from Hello VizHub

This example shows a horizontal bar chart of the 2020 populations of the world’s most populous countries, ranked from largest at the top to smallest at the bottom, with populations displayed in billions. Built with React and D3.js, it uses `d3.scaleBand` for the categorical country axis and `d3.scaleLinear` for the population axis, rendering each bar as an SVG rectangle. Data is loaded asynchronously via D3’s `d3.csv` from a remote GitHub dataset, and hovering over a bar reveals its precise value using an SVG `<title>` tooltip.

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.