Skip to main content
100%

Question 2: Pie Chart

✓ Published3🌍 Public
Sshreshnaanugu@gmail.com
Last edited Oct 27, 2025
Created on Oct 27, 2025

This example visualizes product revenue distribution as an interactive pie chart, with slices colored by product and sized by aggregated revenue from a CSV file loaded via `d3.csv()`. The SVG-based chart uses `d3.pie()` and `d3.arc()` to generate the slices, while hovering highlights a slice with a `transition` animation. A legend and title accompany the chart, and the background uses a CSS gradient. The chart sorts products by revenue and uses an ordinal color scale.

AI-generated description
MIT Licensed

Similar vizzes