Skip to content

Instantly share code, notes, and snippets.

@the-greenman
the-greenman / index.html
Last active December 15, 2015 20:48 — forked from enjalot/index.html
<!DOCTYPE html>
<html>
<head>
<title>Pie Chart</title>
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.js?2.3.0"></script>
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.layout.js?2.3.0"></script>
<style type="text/css">
body {
font: 10px sans-serif;

A sunburst is similar to the treemap, except it uses a radial layout. The root node of the tree is at the center, with leaves on the circumference. The area (or angle, depending on implementation) of each arc corresponds to its value. Sunburst design by John Stasko. Data courtesy Jeff Heer.

@the-greenman
the-greenman / README.md
Last active December 14, 2015 18:59 — forked from mbostock/.block

This donut chart is constructed from a CSV file storing the populations of various age groups. The chart employs a number of D3 features: