🌍 Public
Viewing a saved revision (read-only)
6843937727534c4ea7e34de2963d4d3e
question2
A stacked bar chart shows vehicle sales across five brands, with each bar divided into three color-coded car categories: SUV, sedan, and mini. The chart uses D3 v7's `d3.stack()` and `d3.scaleBand()` to position horizontal bars, with `d3.scaleLinear()` mapping the sales totals. Hovering over a segment triggers a tooltip displaying the exact sales value for that brand and category, using D3 event handlers for mouseover, mousemove, and mouseout interactions.
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.