🌍 Public
Viewing a saved revision (read-only)
96ad12c83f704c7da9239c091560a685
Activity6-Question-1.2
This bar chart displays the population of 20 countries in 2010, with horizontal bars sorted alphabetically by country name and scaled linearly by population. The visualization uses React alongside D3 v5’s `scaleBand`, `scaleLinear`, and `csv` for data loading, rendering SVG rectangles through the custom `Marks` component. Axes are generated by `AxisBottom` and `AxisLeft`, with formatted tick labels using `format('.2s')` and a tooltip via `<title>`. Tick lines are styled blue and bars green, with data sourced from a remote CSV file.
AI-generated descriptionAn example showing the capabilities of VizHub:
- Loads D3 via UNPKG.
- Demonstrates use of
importfrom"d3". - Demonstrates use of
importfrom local ES6 modules.