ICE 7 - Pie Chart
✓ Published0🌍 Public
This pie chart displays the income of the top 10 Indian states for the financial year 2011–12, with each slice colored via d3.scaleOrdinal and d3.schemeCategory10. The data is loaded from a CSV using d3.csv, sorted, and sliced before being rendered with d3.pie and d3.arc. A custom legend, built with SVG rectangles and text, shows each state’s name and income value alongside its color. Mouseover events log the corresponding income value to the console.
AI-generated descriptionA demonstration of how to start using D3 version 6.
MIT Licensed