🌍 Public
Viewing a saved revision (read-only)
8afe1207809e4fa1b1cfdc7c294b752f
Pie Chart
This example displays a pie chart of sales figures for different companies, with each segment labeled by its proportional value and paired with a legend showing company names and sales totals. The chart is rendered as SVG using D3 v5, with data fetched from a CSV URL. It uses D3’s `pie` and `arc` generators to create the segments, a `scaleOrdinal` to map sales values to a set of predefined colors, and custom text elements to label each slice.
AI-generated description