🌍 Public
Viewing a saved revision (read-only)
8df459e9c46647d1bebe4d5dc7e9a1a9
d3.js learning
A stacked bar chart shows the changing counts of four fruit varieties (Red Delicious apples, McIntosh apples, oranges, and pears) across the years 2006–2016. The d3.v3 code builds the visualization from inline JavaScript data using `d3.layout.stack` for layered series, `d3.scale.ordinal` for the time-based x-axis, and `d3.svg.axis` for axes with custom tick formatting. Hovering reveals a value tooltip, and a legend identifies each color-coded segment. The SVG rendering is achieved through appended `<rect>` elements.
AI-generated description