Skip to main content
100%

Pie Chart

✓ Published0🌍 Public
SSRI RAM REDDY KOTERU
Last edited Mar 27, 2022
Created on Mar 27, 2022
Forked from [TEST] Pie Chart

This example visualizes rating distributions as a pie chart, where each slice represents a categorical rating (such as "AAA Local" or "BBB- Internacional") with its corresponding percentage value. The chart reads input data from a JSON file and displays each category with a color-coded slice, accompanied by a legend on the right listing the label and exact percentage. Built with D3 v5, the code uses the `pie` layout generator to compute arc segments, `arc` for rendering paths, and `scaleOrdinal` for categorical color assignment. The SVG output is generated using the `select` and `append` API to construct both the pie slices and the legend elements.

AI-generated description
MIT Licensed

Similar vizzes