Skip to main content
100%

Q1.2

✓ Published0🌍 Public
MMandadi Nishita
Last edited Oct 20, 2024
Created on Oct 20, 2024
Forked from Q1.1

This example displays a horizontal bar chart of population data for 20 countries in 2010, using green bars sorted alphabetically by country name. It loads CSV data from a GitHub repository via D3's `csv` function and renders the chart as SVG through React components. The code imports React, ReactDOM, and D3 v5 functions including `scaleBand`, `scaleLinear`, `scaleLinear`, `max`, and `format`, with custom `AxisBottom`, `AxisLeft`, and `Marks` components handling tick marks, labels, and tooltips.

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