Skip to main content
100%

PIECHART-SUBHASH

✓ Published1🌍 Public
SSubhash
Last edited Oct 27, 2025
Created on Oct 27, 2025

This D3.js donut chart example, PIECHART-SUBHASH, displays device share percentages (e.g., mobile, desktop, tablet) as colored slices with rounded corners and padding. It shows percentage labels outside the donut, connected by leader lines, alongside a legend on the right. The code builds a reusable pie chart component using `d3.pie`, `d3.arc`, and `d3.scaleOrdinal` with a Tableau10 palette, rendering to SVG via the D3 `.join()` pattern. The chart uses hardcoded demo data and supports configurable inner radius, corner radius, and label formatting.

AI-generated description
MIT Licensed

Similar vizzes