Skip to content

Instantly share code, notes, and snippets.

@etachov
etachov / fad_2013_rol.csv
Created March 28, 2015 17:38
Tachovsky Mod 2 Assignment
country.code country objective.name total.disbursed gdp.percapita.ppp fh.fotp
AF Afghanistan Rule of Law and Human Rights 33339657.95 1946.193806 66
AL Albania Rule of Law and Human Rights 2056420 10374.01564 49
AO Angola Rule of Law and Human Rights 15385.24 7736.174682 69
AM Armenia Rule of Law and Human Rights 452966.2 7776.286043 62
AZ Azerbaijan Rule of Law and Human Rights 976360.28 17143.47923 84
BD Bangladesh Rule of Law and Human Rights 3128443 2948.01489 54
BO Bolivia Rule of Law and Human Rights -65121 6131.061689 48
BA Bosnia and Herzegovina Rule of Law and Human Rights 1423785.2 9535.539791 50
BR Brazil Rule of Law and Human Rights 170098 15037.45747 45
country objective disbursed
Kenya Counterterrorism 5297145.2
Mali Counterterrorism 4920931.2
Egypt Counterterrorism 2628123
Morocco Counterterrorism 1500857
Pakistan Counterterrorism 1493790
Colombia Counterterrorism 1287168
Uganda Counterterrorism 1094019
Yemen Counterterrorism 1005153
Afghanistan Counterterrorism 869230
@etachov
etachov / ct_aid.csv
Created April 11, 2015 19:16
Tachovsky Mod 4 Assignment
Kenya Counterterrorism 5297145.2
Mali Counterterrorism 4920931.2
Egypt Counterterrorism 2628123
Morocco Counterterrorism 1500857
Pakistan Counterterrorism 1493790
Colombia Counterterrorism 1287168
Uganda Counterterrorism 1094019
Yemen Counterterrorism 1005153
Afghanistan Counterterrorism 869230
@etachov
etachov / ct_fh_aid.csv
Created April 27, 2015 00:54
Tachovsky Assignment 5
country objective disbursed fh
Kenya Counterterrorism 5297145.2 57
Mali Counterterrorism 4920931.2 37
Egypt Counterterrorism 2628123 68
Morocco Counterterrorism 1500857 66
Pakistan Counterterrorism 1493790 64
Colombia Counterterrorism 1287168 54
Uganda Counterterrorism 1094019 58
Yemen Counterterrorism 1005153 76
Afghanistan Counterterrorism 869230 66
@etachov
etachov / ct_aid.csv
Created April 27, 2015 00:58
CT aid dot plot
Kenya Counterterrorism 5297145.2
Mali Counterterrorism 4920931.2
Egypt Counterterrorism 2628123
Morocco Counterterrorism 1500857
Pakistan Counterterrorism 1493790
Colombia Counterterrorism 1287168
Uganda Counterterrorism 1094019
Yemen Counterterrorism 1005153
Afghanistan Counterterrorism 869230
@etachov
etachov / index.html
Created April 27, 2015 01:10
Tachovsky Assignment 6
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Political Stability in Africa</title>
<script type="text/javascript" src="http://d3js.org/d3.v3.js"></script>
<style type="text/css">
body {
background-color: white;
@etachov
etachov / index.html
Created April 27, 2015 01:24
d3 glitch clouds
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Conditional Styling</title>
<script type="text/javascript" src="http://d3js.org/d3.v3.js"></script>
<style type="text/css">
body {
background-color: white;
@etachov
etachov / index.html
Created June 15, 2015 17:29
Sample PR Chart
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>MDIF Portfolio by Freedom House and GNI</title>
<script type="text/javascript" src="http://d3js.org/d3.v3.js"></script>
<style type = "text/css">
body {
background-color: #fff;
@etachov
etachov / kasich_trips.csv
Last active August 29, 2015 14:25
Quick parse of Columbus Dispatch StoryMap data on Kasich fundraising trips
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 9.
"lat","lon","date","date_formatted","details"
42.9956397,-71.4547891,"March 24, 2015",2015-03-24,"Manchester, N.H. Kasich gets a taste of New Hampshire folks' vetting of candidates"
40.7127837,-74.0059413,"March 25, 2015",2015-03-25,"New York City Conservatives questions Kasich's support of Medicaid expansion in NYC"
44.3106241,-69.7794897,"March 25, 2015",2015-03-25,"Augusta, Maine Faber travels to Maine to join Kasich"
42.331427,-83.0457538,"April 13, 2015",2015-04-13,"Detroit, Mich. Gov. John Kasich 'seriously considering' running for president"
34.8526176,-82.3940104,"April 17, 2015",2015-04-17,"Greenville, S.C. Kasich gets some pushback in South Carolina"
42.7653662,-71.467566,"April 18, 2015",2015-04-18,"Nashua, N.H. Kasich shares message, makes friends on the road"
38.9071923,-77.0368707,"April 23, 2015",2015-04-23,"Washington, D.C. Kasich, speaking in Washington, discusses potential presidential runSee the video"
38.9071923,-77.0368707,"May 1, 2015",2015-05-01,"Washington, D.C. Kasich defends his dire
@etachov
etachov / timeline_gif.R
Created February 28, 2016 18:41
Make a timeline gif using ggplot, gganimate and ggrepel
### make a timeline gif of upcoming elections using data from IFES
library(ggplot2) # plotting engine
library(dplyr) # data manipulation
library(ggrepel) # smart plot labels
library(gganimate) # easy gif-making
library(lubridate) # dealing with date-time
library(RColorBrewer) # color scale