Activity6_population
✓ Published0🌍 Public
This example visualizes the top ten countries by population in 2000 as a horizontal bar chart. Using a d3.scaleLinear for the x-axis and d3.scaleBand for the y-axis, it renders SVG rectangles with steelblue fill. The code loads data from a CSV via d3.csv, sorts it descending, and formats axis tick labels in millions. Axes are created with d3.axisBottom and d3.axisLeft, with custom text labels for both dimensions.
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.
MIT Licensed