🌍 Public
Viewing a saved revision (read-only)
bf1065281e304e8bb0cccb14bd9dffa2
Activity 7
This example shows the market share of smartphone brands as a static pie chart with a legend identifying each brand by color. The visualization is rendered as an SVG using D3.js v5, with data loaded from a CSV file hosted on GitHub. The code uses `d3.csv` to parse the data, `d3.pie` to compute the angular layout, `d3.arc` to generate the pie slice paths, and `d3.scaleOrdinal` to assign colors from a predefined categorical palette. The chart includes a legend of circles and text labels, along with a title and axis labels for context.
AI-generated description