Coder Social home page Coder Social logo

mbarger2 / 2019-04-democratic-candidate-codonors Goto Github PK

View Code? Open in Web Editor NEW

This project forked from buzzfeednews/2019-04-democratic-candidate-codonors

0.0 0.0 0.0 4.86 MB

Data and code supporting a BuzzFeed News article examining donors who gave more than $200 to multiple Democratic presidential candidates in the first quarter of the 2020 election cycle, published April 16, 2019.

Home Page: https://www.buzzfeednews.com/article/tariniparti/democratic-donors-2020-candidates

Makefile 0.08% Jupyter Notebook 99.92%

2019-04-democratic-candidate-codonors's Introduction

Analysis of early 2020 Democratic campaign co-donors

This repository contains data and code supporting a BuzzFeed News article examining donors who gave more than $200 to multiple Democratic presidential candidates in the first quarter of the 2020 election cycle, published April 16, 2019. See below for details.

Data

All data in this repository comes from the campaigns' committee filings to the Federal Election Commission (FEC), with assistance from ProPublica's Campaign Finance API.

  • inputs/candidates.csv contains a list of high- and medium-profile Democratic presidential candidates (and primary campaign committees) for whom an "April Quarterly" filing was available on the FEC's website by 6:30am Eastern on April 16, 2019. (The filing deadline was April 15 at midnight.)

  • inputs/filings.csv contains a list of basic metadata for the aforementioned filings.

  • The inputs/filings/ directory contains the raw filing data for each of those filings, in the FEC's .fec format.

Methodology

Linking donors

The Federal Election Commission filings do not contain any truly-unique identifiers for campaign contributors. So, in order identify donors who have given to multiple campaigns, BuzzFeed News constructed a donor_id, created from the following fields:

  • First name
  • Last name
  • 5-digit ZIP code

There are some limitations to this approach:

  • If a donor changes their name, or misspells it occasionally, this approach will not cluster all of their contributions together
  • If a donor moves to a new ZIP code, this approach will not cluster all of their contributions together
  • If two or more donors in the same ZIP code share both a first and last name, this approach will assume (incorrectly) that they are the same person

For these reasons, the results of the analysis should be interpreted as approximations.

The $200 threshold

The Federal Election Commission does not require campaigns to itemize contributions from donors who have given $200 or less during a given campaign cycle. In a small number of cases, however, campaigns have included such donors — often, it seems, because they gave a large amount of money and then were refunded. For the sake of equal comparison, BuzzFeed News excluded contributions from donors whose aggregate was listed as $200 or less.

Contribution totals above legal limit

The FEC prohibits individual donors from giving more than $2,800 to any single committee. Even so, the data in the filings appear to indicate that some donors have given more than that amount. In some cases, this may be because the refunds have not yet been processed, or are declared elsewhere. Above-legal contributions have no effect on the analyses, which focus on the act of giving rather than how much money the campaigns have raised.

Analysis

The notebooks/analyze-campaign-codonors.ipynb notebook contains the analysis, written in Python. Relevant outputs can be found there, as well as in the outputs/ directory.

Outputs

The outputs/ directory contains two files that may be of interest to other journalists and researchers:

In both files, combinations are not exclusive. For instance, someone who gave to four candidates will be counted for each permutation (i.e., six pairs and four triplets).

Reproducibility

The code running the analysis is written in Python 3, and requires the following Python libraries:

  • pandas for data loading and analysis
  • fecfile for parsing the raw FEC filings
  • jupyter to run the notebook infrastructure

If you use Pipenv, you can install all required libraries with pipenv install.

Executing the notebook in the notebooks/ directory should reproduce the findings.

Licensing

All code in this repository is available under the MIT License. Files in the input/ directory are released into the public domain. Files in the output/ directory are available under the Creative Commons Attribution 4.0 International (CC BY 4.0) license.

Questions / Feedback

Contact Jeremy Singer-Vine at [email protected].

Looking for more from BuzzFeed News? Click here for a list of our open-sourced projects, data, and code.

2019-04-democratic-candidate-codonors's People

Contributors

jsvine avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.