04 · Blog

Occasional writing

Notes on R, Congress, and computational social science.

2026
may 13, 2026 · MIT Election Data and Science Lab · 13 min read

Inside the 2024 Precinct Project

How MEDSL collected, cleaned, validated, and released a nationwide dataset of precinct-level returns from the 2024 general election — and where AI tools fit into the workflow.

Tile-grid map of US states showing the source of each state's 2024 precinct-level election data
2024
oct 3, 2024 · 25 min read

Coding for Others: Creating an R Package for Specification Curve Analysis

The motivation behind and process of developing speccurvieR — an R package for specification curve analysis — demonstrated on Starbucks and replication data.

speccurvieR specification curve plot
2020
mar 21, 2020 · 4 min read

Congressional Twitter and Coronavirus

Scraping members of Congress' tweets to see how they talked about COVID-19 — by term, party, and chamber — as the pandemic unfolded.

Chart of congressional tweeting about coronavirus over time
2019
dec 24, 2019 · 2 min read

Python + Reddit + Google Sheets, a fun and frustrating combination

A Thanksgiving-break proof-of-concept: scraping Reddit with PRAW, piping it into Google Sheets, and learning why you should probably skip the spreadsheet.

Chart of /r/Politics posts mentioning Trump over a day
2019
dec 8, 2019 · 12 min read

Attempts to Crack the Case of the Vanishing Marginals

Four decades of political science on the decline of close U.S. House elections — from Mayhew's original puzzle to polarization and the eroding incumbency advantage.

Chart of House elections in the marginal range, 1956–72
2019
dec 8, 2019 · 12 min read

Climate Change Is Here, So How Does Buffalo Really Fare?

Localizing a global issue: how climate change is already reshaping Western New York — agriculture, lake-effect snow, energy, and the people of Buffalo.

USDA plant hardiness zone map of New York State
2020
jan 24, 2020 · 9 min read

Who Congressional Parties Retweet

Scraping the four congressional party Twitter accounts with Tweepy to see who they retweet — by state, category, age, and ideology.

Bar chart of birth years of members retweeted by a congressional party account