library(chunked) | |
library(tidyverse) | |
# I want to look at the daily page views of Wikipedia articles | |
# before 2015... I can get zipped log files | |
# from here: https://dumps.wikimedia.org/other/pagecounts-ez/merged/2012/2012-12/ | |
# I get bz file, unzip to get this: | |
my_file <- 'pagecounts-2012-12-14/pagecounts-2012-12-14' |
# Use xinput to find your keyboards. | |
$ xinput | |
⎡ Virtual core pointer id=2 [master pointer (3)] | |
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)] | |
⎜ ↳ SynPS/2 Synaptics TouchPad id=11 [slave pointer (2)] | |
⎜ ↳ TPPS/2 IBM TrackPoint id=12 [slave pointer (2)] | |
⎜ ↳ Logitech Performance MX id=14 [slave pointer (2)] | |
⎜ ↳ E-Signal USB Gaming Keyboard id=16 [slave pointer (2)] | |
⎣ Virtual core keyboard id=3 [master keyboard (2)] |
This gist shows how to create an animated world map of life expectancy using R. The data comes the UN World Population Prospects, 2015 Revision, and it brings life expectancy data from 1950 untill 2015 and projeceted data up to 2100. Thanks Topi Tjukanov, who reminded me of the UN DESA data portal, where you can find this dataset and many others
The idea is to use open data to create a GIF, much like the ones created by Aron Strandberg but his maps look much nicer. The output of this script is a map like this one:
[![enter image description here][1]][1]
Now diving into the code. First, let's load the necessary libraries and get the data. As of this writing, the current version of gganimate
has a bug that messes the aesthetics of the .gif
file. As a temporary solution, I've intalled an older version of the package, [as recommended by the author of the gganimate
, David Ro
To colaborate on a gist:
- Clone your gist repo locally
- Add your friend’s fork as a remote
e.g. if your friend is named Cindy:
git remote add-url cindy https://gist.github.com/cindy/df03bdacaef75a80f310
- Fetch your friend’s commits:
git fetch cindy/master
- Merge your friend’s changes into your repo:
git merge cindy/master
- Push the changes back to GitHub:
git push origin/master
Short version: I strongly do not recommend using any of these providers. You are, of course, free to use whatever you like. My TL;DR advice: Roll your own and use Algo or Streisand. For messaging & voice, use Signal. For increased anonymity, use Tor for desktop (though recognize that doing so may actually put you at greater risk), and Onion Browser for mobile.
This mini-rant came on the heels of an interesting twitter discussion: https://twitter.com/kennwhite/status/591074055018582016
This list of resources is all about acquring and processing aerial imagery. It's generally broken up in three ways: how to go about this in Photoshop/GIMP, using command-line tools, or in GIS software, depending what's most comfortable to you. Often these tools can be used in conjunction with each other.
- USGS Earth Explorer - Browser and data access (create a login)
http://earthexplorer.usgs.gov/
- Landsat archive
# United States of America Python Dictionary to translate States, | |
# Districts & Territories to Two-Letter codes and vice versa. | |
# | |
# Canonical URL: https://gist.github.com/rogerallen/1583593 | |
# | |
# Dedicated to the public domain. To the extent possible under law, | |
# Roger Allen has waived all copyright and related or neighboring | |
# rights to this code. Data originally from Wikipedia at the url: | |
# https://en.wikipedia.org/wiki/ISO_3166-2:US | |
# |