Unlike choropleth maps, cartograms encode data using area rather than color, resulting in distorted geographic boundaries. In this example, states are rescaled around their centroid, preserving local shape but not topology. Inspired by Zachary Johnson. Non-continguous cartogram design invented by Judy Olsen. U.S. state and county boundaries from the U.S. Census Bureau, simplified using GDAL and MapShaper.
This file contains hidden or 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
| 442 |
This file contains hidden or 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
| require 'rubygems' | |
| require 'leftronic' | |
| update = Leftronic.new "API_KEY" | |
| point = {'html' => '<h1>Hello World!'} | |
| update.push_number "STREAM_NAME", point |
This file contains hidden or 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
| var o = {'cat': 'meeauw', 'dog':'woof', 'frog': 'ribbit'}; | |
| > undefined | |
| delete o.cat | |
| > true | |
| o.dog = null; | |
| > null | |
| for (i in o) { console.log(i); } | |
| dog | |
| frog |
This file contains hidden or 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
| var foo = function () { console.log('foo'); } | |
| undefined | |
| function bar() { console.log('bar'); } | |
| undefined | |
| foo.toString(); | |
| "function () { console.log('foo'); }" | |
| bar.toString(); | |
| "function bar() { console.log('bar'); }" |
This file contains hidden or 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
| Sampling process 14766 for 3 seconds with 1 millisecond of run time between samples | |
| Sampling completed, processing symbols... | |
| Analysis of sampling Chocolat (pid 14766) every 1 millisecond | |
| Process: Chocolat [14766] | |
| Path: /Applications/Chocolat.app/Contents/MacOS/Chocolat | |
| Load Address: 0x102253000 | |
| Identifier: com.chocolatapp.Chocolat | |
| Version: 1.4.3 (1.4.3) | |
| Code Type: X86-64 (Native) | |
| Parent Process: launchd [224] |
This file contains hidden or 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
| curl -vvv http://pixoent.com/development/Dashboards/averageEventLength.php?apiKey=SDCYMDPJ83TX8Y6DVHB7&event=Hwy2 | |
| [2] 16295 | |
| [1] Done curl -vvv http://pixoent.com/development/Dashboards/averageEventLength.php?apiKey=SDCYMDPJ83TX8Y6DVHB7 | |
| bjorn@Bjorns-MacBook-Pro:~$ * About to connect() to pixoent.com port 80 (#0) | |
| * Trying 99.198.113.34... | |
| * connected | |
| * Connected to pixoent.com (99.198.113.34) port 80 (#0) | |
| > GET /development/Dashboards/averageEventLength.php?apiKey=SDCYMDPJ83TX8Y6DVHB7 HTTP/1.1 | |
| > User-Agent: curl/7.24.0 (x86_64-apple-darwin12.0) libcurl/7.24.0 OpenSSL/0.9.8r zlib/1.2.5 | |
| > Host: pixoent.com |
This file contains hidden or 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>Your Leftronic Dashboard</title> | |
| <style type="text/css"> | |
| * { | |
| margin:0; | |
| padding:0 | |
| } | |
| body, html { |
This file contains hidden or 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 type="text/javascript" src="http://mbostock.github.com/d3/d3.v2.js"></script> | |
| <style type="text/css"> | |
| svg { | |
| border:1px solid gray | |
| } | |
| #countries path { |
This file contains hidden or 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
| // http://www.html5rocks.com/en/tutorials/file/dndfiles/ | |
| d3.select('svg') | |
| .on('dragover', handleDragOver) | |
| .on('drop', handleFileSelect) | |
| ; | |
| function handleFileSelect() { | |
| var event = d3.event | |
| , files = event.dataTransfer.files // FileList object | |
| , about = [] |