Skip to main content
Public

Share visualization

Loading preview…

Fork of ICE 7 - Pie Chart

vizhub.com

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

Before sharing, review the publishing checklist.

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 & exportPNG, HTML, source ZIP

Fork of ICE 7 - Pie Chart

0
Ccharanchand9
Last edited Jul 3, 2022
Created on Jul 3, 2022
Forked from ICE 7 - Pie Chart

This visualization presents a pie chart ranking the top 10 countries by deaths attributed to air pollution in 2020, with each slice labeled in thousands and a matching legend that pairs country names with their death counts. Using D3 v5, the code fetches CSV data via `d3.csv`, computes a pie layout with `d3.pie()`, and draws arcs with `d3.arc()`. Slice colors come from a `d3.scaleOrdinal` palette, and text labels are positioned using the arc generator’s `centroid` method. The SVG rendering includes custom legend groups and formatted tick labels via `d3.format`.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed