Skip to main content
100%

question1.2

✓ Published0🌍 Public
Aajaykumarakula00@gmail.com
Last edited Apr 14, 2024
Created on Apr 14, 2024

This example displays a horizontal bar chart of population data for 20 countries in 2010. The visualization uses React with D3 v5 scale functions, specifically `scaleBand` for the categorical y-axis and `scaleLinear` for the numeric x-axis. The bars are rendered as SVG rectangles, with axes created through custom components that map D3 scales to JSX elements. The chart loads CSV data from a GitHub gist, formats population values using the D3 `format` function, and includes a tooltip showing the formatted value for each bar.

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