Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

activity 6_Task 1

Public visualization

Viewing a saved revision (read-only)

f2a9e9a7190048e79f000a43b88f11c9

activity 6_Task 1

0 stars1🌍 Public
Kkeerthanachinthalapally@gmail.com
Last edited Apr 15, 2024
Created on Apr 14, 2024
Forked from Hello VizHub

This example shows a horizontal bar chart of population data for 20 countries in 2010, with countries listed along the y-axis and population values along the x-axis. The visualization uses React components to render SVG elements, with D3’s scaleBand and scaleLinear mapping data to positions and widths. The code imports csv from d3 to load the dataset from a GitHub gist, while AxisBottom and AxisLeft components generate tick marks and labels. Bars are drawn as SVG rectangles with a light green fill, and hovering reveals a tooltip with formatted population values.

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.