Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Donut Chart v2

Public visualization

Fork of Donut Chart v2

0 stars0🌍 Public
Ttashi.garg@outlook.com
Last edited May 5, 2024
Created on May 5, 2024

This donut chart displays the frequency of three languages—English, Spanish, and German—based on sums from a local JSON file. The chart includes a small legend-free design with labels positioned outside the arcs using custom polylines generated via D3’s `d3.arc` and `outerArc` centroid calculations. Data is loaded asynchronously with `d3.json` and parsed into a pie layout using `d3.pie`, while colors come from the `d3-scale-chromatic` scheme. The visualization filters to the top five entries (here, all three) and renders SVG paths with opacity and stroke styling.

AI-generated description

Un exemple pour le TP.

Comments

Sign in to join the discussion.

MIT Licensed