Fork of pie chart
✓ Published0🌍 Public
This example shows a categorical distribution as a pie chart with a legend. It visualizes five categories with varying values, each slice labeled directly and represented by a distinct color in a separate legend. The chart is built using D3 v6, leveraging `d3.pie` and `d3.arc` generators to compute slice geometry, while `d3.scaleOrdinal` assigns the categorical color scheme. The SVG output is generated from hardcoded data, with the pie centered within a 500-pixel square and a custom-styled HTML legend positioned beside it.
AI-generated descriptionA demonstration of reusable scatter plot.
ISC Licensed