Posts by Year

2017

2016

Data management and missing data

10 minute read

A lot can go wrong between raw data and processed data used for analysis. Here is one post-mortem example and a plot that can help identify issues for countr...

Moving from Wordpress to Jekyll

5 minute read

I moved my home page and blog from Wordpress to Jekyll over the past week, thanks to a small break in regular work. I’ve been using Wordpress.com since 2011,...

3d surface plots of GDP vs. event data

2 minute read

A while ago I wrote a post about how the patterns by which data for cross-national datasets observed over multiple periods, e.g. with country-year or country...

2015

When forecasting goes wrong (maybe): Yemen

10 minute read

Over the past few months we have worked on regularly updating our irregular leadership change models and forecasts in order to provide monthly 6-month ahead ...

Good coup, bad coup

8 minute read

Alexander Noyes and Sebastian Elischer wrote about good coups on Monkey Cage a few weeks ago, in the shadow of fallout from the LaCour revelations. Good coup...

A quick look at the public ICEWS data

3 minute read

The ICEWS data, including the underlying raw event data as well as some aggregations, were quietly posted on Dataverse the Friday before last. I’ve worked wi...

Precision-recall curves

8 minute read

ROC curves are not very good for evaluating model fit with sparse outcomes, like civil war onset or coups. Use precision-recall curves instead.

Archigos leader turnovers by regime

6 minute read

Exploration of data on leadership transitions and how they vary by regime types, using the Archigos data on state leaders and the Polity regime classification.

2014

Building rgdal from source

1 minute read

My limited knowledge of what happens in Terminal, and thus by extension shell, is mostly driven by PostgreSQL/PostGID/rgdal/RPostgreSQL install errors. In th...

The right kind of variance

7 minute read

or, How I learned to stop worrying and love event data. (This post first appeared on Predictive Heuristics)

Baby steps with R Shiny

2 minute read

Shiny is a web application framework that lets you create interactive websites representing R data visualization and analysis. The gallery has some nice exam...

Associating points with polygons in R

2 minute read

Some time ago I posted on how to find geographic coordinates given a list of village or city names in R. Somebody emailed me about how to do the reverse: the...

2013

Defense doublethink

1 minute read

If you had to take a look at the chart below, what would you say about the overall trend in US defense spending? There’s a bump fairly early on for World War...

Time to learn Python

less than 1 minute read

Apparently Python is taking over the world (from a post by Tal Yarkoni):

Taking over the world

1 minute read

I work as a Postdoctoral Fellow in the Ward Lab here at Duke University. The Lab currently consists of Mike Ward, me, and a group of very smart graduate stud...

Quick background maps in R

1 minute read

Sometimes, for whatever reason, you want to plot something fast. Last week I had some coordinates associated with event data that I was hoping were all from ...

Database adventures

1 minute read

Recently I’ve set up both a PostgreSQL and MySQL server to host databases related to some of our projects in the Ward Lab. I should note that I have no idea ...

Finding coordinates for cities, etc. with R

2 minute read

The problem: you have data that includes the name of a village or city in which something happened, but not coordinates for that village or city. This seems ...

What’s in a SIGACT

less than 1 minute read

I've been working with SIGACT data (military significant activities reports) all day as part of a research project. When you are dealing with thousands of th...

Plot of Duke grade inflation

2 minute read

Someone sent around a link this morning to data on grade inflation at Duke, which shows a table of average GPAs for undergraduates from 1932 on. Looking at t...

2012

Scale and north arrow for maps in R

1 minute read

A few months ago I produced some thematic maps of Bosnia (paper) using maptools and other packages in R, but I didn’t include scales or a north arrow. It sou...

Which governments torture?

1 minute read

Almost all states, at least at some point between 1995 and 2005. The Ill-Treatment and Torture (ITT) project by Courtenay Conrad and Will Moore codes Amnesty...

Yugoslavs die less

4 minute read

In 1991 a census was conducted in Bosnia and Herzegovina, which then was still part of the disintegrating federal state of Yugoslavia. Bosnia was the most di...

2011

Running RStudio on Amazon EC2

1 minute read

For the most part I don’t do things that are computationally so intensive that I can’t run them on my work desktop. There have been a few times however where...

The Iraq War, 2003 to 2011

1 minute read

President Obama announced today that U.S. troops will leave Iraq by the end of 2011. What has the 9 year long war accomplished?

Report on COIN intelligence collection

2 minute read

A few months ago the Defense Science Board Task Force on Defense Intelligence released a report on Counterinsurgency (COIN) Intelligence, Surveillance, and R...

Stata Basics

less than 1 minute read

A couple of lab notes from 2009, when I was TA for our Basic Quantitative Methods course:

Programming MLE models in Stata

less than 1 minute read

Another set of notes from when I was TA for our Advanced Quantitative Methods course with Prof. Matt Golder in 2008. The notes for Programming MLE models in ...