Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of assigment-2 D3

Public visualization

Fork of assigment-2 D3

0 stars1🌍 Public
Pprince.sahith100@gmail.com
Last edited Mar 26, 2025
Created on Mar 26, 2025

This example shows the distribution of hypertension risk in a dataset, displayed as a pie chart with two categories: no risk (0) and risk (1). The chart uses D3.js v6 with an SVG rendering approach, loading CSV data from a GitHub gist. It employs d3.pie() and d3.arc() to generate the chart slices, with labels showing category names and counts. A color scale assigns distinct colors to each category, and a legend is generated dynamically from the same data.

AI-generated description

Comments

Sign in to join the discussion.

MIT Licensed