🌍 Public
Viewing a saved revision (read-only)
b7e18c6eecad4064b25a8c00fdadec65
ICE 7 - Pie chart for Mobiles sales
This example displays a pie chart of mobile sales by brand, with each slice labeled by its sales value and accompanied by a legend showing brand names and corresponding figures. It imports data from a CSV file using `d3.csv` and renders the chart as an SVG. The pie layout (`d3.pie`) and arc generators (`d3.arc`) create the slices, while a `scaleOrdinal` maps sales values to a fixed array of section colors, with text and legend elements positioned manually.
AI-generated description