Skip to main content
100%

Activity 6_2000

✓ Published0🌍 Public
JJaiyaGhanta@my.unt.edu
Last edited Oct 22, 2024
Created on Oct 22, 2024

This example displays a horizontal bar chart comparing the populations of the top 10 countries in the year 2000, with country names on the y-axis and population totals on the x-axis. The chart is rendered as an SVG using React components, with scales created via d3.scaleBand and d3.scaleLinear. Data is loaded from a CSV file using d3.csv, and axis ticks are formatted with d3.format to abbreviate large numbers (e.g., converting billions to "B"). Hovering over a bar reveals a tooltip with the exact population value.

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