Skip to content

Instantly share code, notes, and snippets.

@GerHobbelt
GerHobbelt / README.json
Created September 16, 2012 15:41
d3.js: mouse drag a la iphone: decceleration
{
"tip_of_the_day": [
{
"title": "Introduction",
"description": [
"A huge image is shown on screen; you can pan/zoom the image to see all the detail or the entire image at once.",
"Each of the possible operations can be performed by one of several mouse actions, some operations can also be performed using the keyboard."
]
},
{
@GerHobbelt
GerHobbelt / README.md
Created September 16, 2012 14:22 — forked from gtb104/README.markdown
Polybrush Example

Here's a d3 plugin that allows you to create a polygon selection. You instantiate it just like d3.svg.brush.

var brush = d3.svg.polybrush();

It has an extra public method that 'brush' does not, and that's 'isWithinExtent(x, y)'. You can use this method to test if a given point falls within the drawn extent.

if (brush.isWithinExtent(x, y)) {
  console.log("I'm inside!");
}
@GerHobbelt
GerHobbelt / index.html
Created September 11, 2012 10:25
d3.js: axis new and vanilla comparison side-by-side
<html>
<head>
<style>
iframe.side-by-side
{
float: left;
border: 2px #aaa solid;
width: 1040px;
height: 15000px;
margin: 0;
@GerHobbelt
GerHobbelt / Konachan.com-46061.black_lagoon.revy.960.jpg
Created September 11, 2012 07:20
d3.js: Q: pack layout with images
Konachan.com-46061.black_lagoon.revy.960.jpg
@GerHobbelt
GerHobbelt / README.md
Created September 11, 2012 01:23 — forked from phoebebright/data.csv
D3 using nest on csv data
@GerHobbelt
GerHobbelt / .gitignore
Created September 9, 2012 09:35
d3.js: Mike Bostocks talk (2011/09) as gist (force layout with multiple foci examples)
# Editor backup files
*.bak
*~
@GerHobbelt
GerHobbelt / .gitignore
Created September 9, 2012 08:04
d3.js: using tree layout for graphs which have nodes with multiple 'parents'
# Editor backup files
*.bak
*~
@GerHobbelt
GerHobbelt / .gitignore
Created September 8, 2012 03:29 — forked from bsr203/index.html
Help on mapping to Cartesian coordinate (log scale)
# Editor backup files
*.bak
*~
@GerHobbelt
GerHobbelt / .gitignore
Created September 8, 2012 03:06 — forked from bsr203/index.html
Help on mapping to Cartesian coordinate
# Editor backup files
*.bak
*~
@GerHobbelt
GerHobbelt / .gitignore
Created September 8, 2012 00:29
d3.js: force layout: using custom tick handler to draw a tree/hierarchy
# Editor backup files
*.bak
*~