Skip to main content
Public

Share visualization

Loading preview…

Fork of Fork of Pie Chart

vizhub.com

Shared links may look like this on X, LinkedIn, Slack, and Discord.

Choose how to deliver this visualization

LinkedIn caption

LinkedIn may not keep text supplied by the share sheet. Copy the caption and paste it into the post if needed. You can tag the VizHub company page when posting.

More options

Embed on a websiteCopy iframe embed code
Download & exportHTML, source ZIP

Fork of Fork of Pie Chart

0 stars0Public
Bbhargavarathod
Last edited Mar 28, 2022
Created on Mar 28, 2022
Forked from Fork of Pie Chart

This example shows the protein content of various cereals as a pie chart, with each slice labeled in the legend alongside its gram value. The chart reads CSV data from a GitHub gist using `d3.csv` (via `getData.js`), then renders SVG paths with `d3.pie`, `d3.arc`, and `d3.scaleOrdinal` for color mapping. Legends are appended as grouped rectangles and text, with values formatted using `d3.format`. The visualization is built with D3 v5, rendered entirely in SVG, and includes a red heading for emphasis.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed