Skip to main content
100%

Actitvity7:Questions:1

✓ Published0🌍 Public
Ssaivaishnogaruda@gmail.com
Last edited Nov 4, 2024
Created on Nov 4, 2024

This example shows the distribution of fuel types among cars using a static pie chart. Hardcoded sample data assigns percentages to petrol, diesel, electric, and hybrid vehicles, with each slice labeled and colored using a categorical scale. The visualization is rendered with D3.js v6, using `d3.pie()` to compute arc angles and `d3.arc()` to draw SVG paths. A custom legend built from HTML divs lists each fuel type with its corresponding color and value.

AI-generated description
MIT Licensed

Similar vizzes