Skip to main content
100%

Question-1_Activity7.1

✓ Published1🌍 Public
Ppreethimedepalli4@gmail.com
Last edited Nov 5, 2024
Created on Nov 5, 2024
Forked from Hello VizHub

A pie chart displays the distribution of sales counts across product categories, with each slice labeled in thousands and a corresponding legend showing category names and values. The visualization loads CSV data from a GitHub gist and uses D3 v5 APIs including `d3.csv`, `d3.pie`, `d3.arc`, `d3.scaleOrdinal`, and `d3.format` to generate SVG paths and text elements. Colors are assigned via an ordinal scale mapping categories to a fixed array of named colors, and the chart is centered within an SVG canvas with legends positioned to the right.

AI-generated description

An example showing the capabilities of VizHub:

  • Loads D3 via UNPKG.
  • Demonstrates use of import from "d3".
  • Demonstrates use of import from local ES6 modules.
MIT Licensed

Similar vizzes