ICE - 7 Pie Chart Divya Kota
✓ Published0🌍 Public
This pie chart visualizes the top 10 countries’ deaths in 2020 attributed to air pollution, using a colorful segmented donut-style layout with each slice labeled by its death count in thousands. The chart is rendered in SVG and built with React, leveraging D3 v5 APIs including `d3.pie`, `d3.arc`, `d3.scaleOrdinal`, and `d3.format` to generate the arcs and legend. Data is loaded asynchronously from a CSV file via `d3.csv`, and each slice’s fill color is mapped from a fixed array. A legend on the right pairs country names with their corresponding death values.
AI-generated descriptionReact Starter code.
MIT Licensed