Under Terminal > Preferences... > (Profile) > Advanced, "Declare terminal as:" should be set to xterm-256color
.
This is easy with homebrew:
brew install screen
license: gpl-3.0 | |
redirect: https://observablehq.com/@d3/margin-convention |
license: gpl-3.0 |
NOTE: This how-to was written for the Census API at http://thedataweb.rm.census.gov/ -- it has since been moved to http://api.census.gov/ | |
Mike Stucka, our contact at the Macon Telegraph, sent us a link to the Census's official API which is launching next month. You can skip ahead to the site - http://www.census.gov/developers/ - and get an API key, but also read my notes after using this yesterday: | |
1) The datasets | |
--- The 2010 Census Summary comes from everyone filling out census forms, and you can get stats at state level down to a super-detailed block level. Info from this includes population, age, gender, race, home ownership, members of a household, and various combinations of that. Full list: http://www.census.gov/developers/data/sf1.xml | |
--- The 2006-2010 American Community Survey is a longer form given to fewer households over 5 years (so its numbers are incompatible with the 2010 Census). You can get stats down only to the block group level. In addition to the standard census stats, you get: educa |
Under Terminal > Preferences... > (Profile) > Advanced, "Declare terminal as:" should be set to xterm-256color
.
This is easy with homebrew:
brew install screen
function spy(layer, callback) { | |
var inflight = {}; | |
var rt = layer.requestManager.requestTile; | |
layer.requestManager.requestTile = function() { | |
inflight[arguments[0]] = +new Date(); | |
rt.apply(layer.requestManager, arguments); | |
}; | |
layer.requestManager.addCallback('requestcomplete', function(s, img) { | |
callback(+new Date() - inflight[img.id]); | |
delete inflight[img.id]; |
license: gpl-3.0 | |
redirect: https://observablehq.com/@mbostock/fetch-progress |
Provide selection capabilities for DOM elements, geared to <select multiple>
.
click
: select elementctrl + click
: add element to current selectionclick + move
: select elements while draggingctrl + a
: select all elements within focused listctrl + shift + a
: deselect all elements within focused listctrl + click + move
: toggle selection while draggingshift + click
: select range from nearest last selected element to clicked elementshift + ctrl + click
: add range to current selectionlicense: gpl-3.0 | |
height: 600 | |
border: no |
var mapLink = "http://maps.google.com/maps?z=12&t=m&q=loc:" + lat + "+" + lon | |
if ($.os.ios && navigator.userAgent.match(/iPhone OS 6_/)) mapLink = "Maps://?q=" + lat + "," + lon | |
if ($.os.android) mapLink = "geo:" + lat + "," + lon + "?z=12&q=" + lat + "," + lon | |
// assumes you have zepto and zepto.detect loaded | |
// also you should use target=_blank on your <a> tags |
<!DOCTYPE html> | |
<head> | |
<meta charset='utf-8'> | |
<title>d3 input table</title> | |
<style> | |
body { | |
font:normal 14px/20px 'Helvetica Neue', sans-serif; | |
} | |
</style> | |
</head> |