Skip to main content
100%

Pie Chart

✓ Published0🌍 Public
EEndNight95
Last edited Jun 15, 2018
Created on Jun 7, 2018

This example visualizes the relative population sizes of two abalone gender categories, with one representing a 'dangerous' proportion, using a donut-style pie chart. The chart is rendered as SVG, and the data is loaded from a local CSV file that is derived from the UCI Machine Learning Repository's Abalone data set. The code uses D3 v4's `d3.pie`, `d3.arc`, and `d3.scaleOrdinal` to compute the arc geometries and apply colors, and it integrates a categorical color legend via the `d3.legend` library. The visualization positions the pie chart centrally within the SVG and displays the legend off to the right, all set against a black background.

AI-generated description

This data is from UCI Machine Learning Repository: Abalone Data Set .

This data set mainly describes the Sex/Length/Diameter/Height/WHole weight/Shucked weight/Viscera weight/Shell weight/RIngs of abolonies.

forked from <a href='http://bl.ocks.org/curran/'>curran</a>'s block: <a href='http://bl.ocks.org/curran/fe735c750f55491c1ea80f022ba7d7cd'>Donut Chart</a>

forked from <a href='http://bl.ocks.org/thomaxyu001/'>thomaxyu001</a>'s block: <a href='http://bl.ocks.org/thomaxyu001/83e632d45a8651f6869eeac332b8f044'>abalone donut chart</a>

mit Licensed

Similar vizzes