[ Launch: kijani horizon static ] fafc8871339b71fdb4f2 by hyonschu[ Launch: kijani horizon ] 69d60fc68a1f78616862 by enjalot[ Launch: simple horizon++ ] 776f3cff0830ca6958a1 by enjalot[ Launch: simple horizon++ ] de713c5d78463d41e09c by enjalot
[ Launch: radial ] 3d09d0a255b262b4bc40 by hyonschu[ Launch: radial ] c11d3c3df4f53880061d by tborychowski
[ Launch: sin waves ] 7c07067270614844607b by hyonschu See Previous Inlet [ Gist ]
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
d3.csv('iris.csv', function(data) | |
{ | |
// THIS WORKS: | |
d3.select(".butts2") | |
.on("click", function() { | |
yscale = d3.scale.linear() | |
.domain(d3.extent(data, function(d) {return d.sepalW})) | |
.range([0,h]) |
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
<html> | |
<head> | |
<script src = 'd3.v3.min.js'></script> | |
<script src = 'angular.min.js'></script> | |
</head> | |
<body> | |
<script> | |
h = 300; | |
w = 745; | |
canvas = d3.select("body") |
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
d3.csv('iris.csv', function(data) | |
{ | |
canvas.selectAll("g") | |
.data(data) | |
.enter() | |
.append('circle') | |
.attr({ | |
'cx': function(d, i) { | |
return i*5; | |
}, |
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> | |
<style type="text/css"> | |
.yaxis path, | |
.yaxis line, | |
.xaxis path, | |
.xaxis line { | |
fill: none; | |
stroke: #222; |
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> | |
<style type="text/css"> | |
.yaxis path, | |
.yaxis line, | |
.xaxis path, | |
.xaxis line { | |
fill: none; | |
stroke: #222; |
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> | |
<script src="angular.min.js"></script> | |
<script src="d3.v3.min.js" charset="utf-8"></script> | |
</head> | |
<body ng-app="myApp"> | |
<iris-chart> | |
<script> | |
var myApp = angular.module('myApp', []); |
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
def fib(length): | |
first, second = 1, 1 | |
if length < 2: | |
return length | |
else: | |
length -= 2 | |
for i in range(length): | |
second, first = first+second, second | |
return second |