Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Activity6_Question2

Public visualization

Viewing a saved revision (read-only)

a11e8eadd0e348c7a960f9957b0daacb

Activity6_Question2

0 stars0🌍 Public
SSai Praveen Lokavarapu
Last edited Apr 5, 2025
Created on Apr 5, 2025
Forked from Hello VizHub

This stacked bar chart visualizes product category sales (Ornaments, Clothes, Electronics) across the years 2018-2021 from the CSV data file. The chart uses D3 v7's `d3.stack()` and `d3.scaleOrdinal` to layer the categorical segments, with SVG rectangles scaled via `d3.scaleBand` for the x-axis and `d3.scaleLinear` for the y-axis. Hovering a segment triggers a tooltip indicating the category and sales value, while a manual legend identifies color-keyed categories on the right side.

AI-generated description