Skip to main content
100%

Activity_7

✓ Published0🌍 Public
Ssaipaidipalli
Last edited Jun 28, 2023
Created on Jun 28, 2023
Forked from Hello VizHub

This example shows a horizontal bar chart of the top 20 countries by 2020 population, using green bars against blue tick marks. The visualization is built with React and D3 v5, employing `scaleBand` for the y-axis, `scaleLinear` for the x-axis, and SVG `rect` elements for the marks. Population values are loaded from a CSV via `d3.csv` and displayed with `d3.format` to abbreviate numbers (e.g., "B" for billions). The chart includes custom axis components and a tooltip using SVG `<title>`.

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