This example uses Voronoi diagrams to estimate the boudaries of each node. For more on Voronoi layout read https://github.com/d3/d3/wiki/Voronoi-Geom
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
license: gpl-3.0 | |
height: 700 | |
border: no |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/> | |
<style type="text/css"> | |
#line{ | |
width: 100%; | |
margin: 20px 0; | |
height: 300px; | |
background: #eee; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function degreeToRadians(value){ | |
return (value/360)*2*Math.PI; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function degreeToRadians(value){ | |
return (value/360)*2*Math.PI; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title></title> | |
<meta charset="utf-8" /> | |
<script src="https://d3js.org/d3.v3.min.js" charset="utf-8"></script> | |
<style type="text/css"> | |
.categories:hover { | |
stroke:dimgray; |
This graph uses least squares method to plot regression line.The size of each circle represents its potassium content.
Dataset: http://www.idvbook.com/teaching-aid/data-sets/
More about least squares method: https://www.youtube.com/watch?v=JvS2triCgOY
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<meta charset="utf-8"> | |
<style> | |
</style> | |
<body> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.17/d3.js" charset="utf-8"></script> | |
<script> | |
var data = [ {name: "one", value: 10375}, | |
{name: "two", value: 7615}, |
NewerOlder