Skip to main content
100%

A10 - 1

✓ Published0🌍 Public
MMike Z
Last edited Nov 23, 2022
Created on Nov 23, 2022
Forked from Fork of Pie Chart

This visualization shows the protein content of various foods as a pie chart, with each segment colored and labeled in a legend. The chart reads data from a CSV file, converts protein values to numbers, and computes the total to render the arcs. Using D3 v5, the code applies the `pie` and `arc` generators, scales colors with `scaleOrdinal`, and formats tick values with `format`. A legend displays each item name and its protein amount in grams, with the SVG positioned at a fixed size.

AI-generated description
MIT Licensed

Similar vizzes