barChart
✓ Published5🌍 Public
This bar chart displays rice production totals for each state, aggregated from district-level crop data using `d3.rollup` and `d3.sum`. The SVG rendering uses `d3.scaleBand` for the x-axis, `d3.scaleLinear` for the y-axis, and `d3.schemeCategory10` for per-state colors. Hovering over a bar triggers a tooltip via D3 transitions, showing the summed production in tons. Data loads asynchronously from a CSV file, with axes drawn using `d3.axisBottom` and `d3.axisLeft`.
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