Skip to main content
100%

Varun_activity_7.1

✓ Published1🌍 Public
VVarunKumarKambhampati@my.unt.edu
Last edited Nov 7, 2024
Created on Nov 7, 2024
Forked from Hello VizHub

This example renders a pie chart from CSV data using D3 v6, visualizing the distribution of values above 8.5 across music genres. It loads data asynchronously via `d3.csv`, converts string values to numbers, and computes arc positions with `d3.pie()` and `d3.arc()`. An ordinal color scale maps genres to `d3.schemeCategory10`, and the SVG output includes a legend built with appended rectangles and text labels. The chart appears within an HTML div, with dimensions and margins set explicitly in the script.

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