Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Untitled

Public visualization

Untitled

0 stars0🌍 Public
AAnjan Shrestha
Last edited Mar 22, 2022
Created on Mar 22, 2022
Forked from pieChart

This example shows a static pie chart displaying the proportional shares of five named individuals (Alex, Shelly, Clark, Matt, and Jolene) as colored slices with labels. The chart is rendered as SVG using D3 v4, with `d3.pie()` computing the arc angles from the data’s `share` values, `d3.arc()` generating the path geometry, and `d3.scaleOrdinal` assigning a categorical color palette. Labels are positioned via `arc.centroid()` and text elements, while the entire visualization is centered within a 500×400 SVG canvas.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed