Skip to main content
100%

Pie_Chart-Task9

✓ Published0🌍 Public
SSree Yuktha Sunkara
Last edited Apr 25, 2024
Created on Apr 23, 2024

This pie chart shows the top five crop yields in Andhra Pradesh for 2017, displaying each crop’s percentage of the total yield as labeled slices with a custom color scale. It uses D3 v5 with `d3.csv`, `d3.pie`, `d3.arc`, and `d3.scaleOrdinal` to load data from a remote ICRISAT CSV, filter by state and year, aggregate yields, and render the SVG chart with an interactive legend. The code computes percentages from summed values and positions text labels using `arc.centroid`.

AI-generated description
MIT Licensed

Similar vizzes