Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

ry0214_Question 1

Public visualization

Viewing a saved revision (read-only)

34479a1d3d4f48db97ebd56a916081f4

ry0214_Question 1

0 stars0🌍 Public
Rreddyyeddula16@gmail.com
Last edited Mar 22, 2025
Created on Mar 22, 2025
Forked from Hello VizHub

This pie chart visualizes the species distribution in the Iris dataset, displaying the proportional counts of setosa, versicolor, and virginica flowers. The D3.js v7 code counts occurrences from an embedded array and renders the chart as an SVG using `d3.pie()` for arc generation and `d3.arc()` for path construction. A categorical color scale (`d3.scaleOrdinal`) assigns distinct hues to each species, with white labels positioned at arc centroids. A horizontal HTML legend below the chart matches colored squares to species names. The dataset contains 150 sample records, though only a subset is listed in the provided code stub.

AI-generated description