Skip to main content
100%

Pie Chart

✓ Published0🌍 Public
Rrajeswariamruthabommaraju@my.unt.edu
Last edited Nov 6, 2024
Created on Nov 6, 2024
Forked from Hi VizHub

This pie chart displays categorical data loaded from a CSV file, with slices colored by category and labeled directly on the chart. It uses D3.js APIs such as `d3.pie()`, `d3.arc()`, and `d3.scaleOrdinal` with `d3.schemeCategory10` to generate and color the SVG paths. Text labels are positioned using `arc.centroid`, and a legend is built with appended rectangles and text elements. The SVG is centered via a transform, and the chart dimensions are fixed at 500 by 500 pixels.

AI-generated description
MIT Licensed

Similar vizzes