Fork of D3 Pie chart
✓ Published1🌍 Public
This pie chart displays the distribution of engine types—Petrol, Diesel, Electric, and Hybrid—within a dataset, with values expressed as percentages. It visualizes categorical proportions using a standard circular layout generated by the D3.js `d3.pie` and `d3.arc` APIs, rendered as SVG paths. Slices are filled with colors from the `d3.schemeCategory10` ordinal scale, and each slice is labeled directly on the chart. A legend, built with custom HTML elements, maps each color to its corresponding engine type and percentage value, using the same color assignment from `d3.scaleOrdinal`.
AI-generated descriptionMIT Licensed