Disclaimer: The purpose of the Open Case Studies project is to demonstrate the use of various data science methods, tools, and software in the context of messy, real-world data. A given case study does not cover all aspects of the research process, is not claiming to be the most appropriate way to analyze a given data set, and should not be used in the context of making policy decisions without external consultation from scientific experts. ####

This work is licensed under the Creative Commons Attribution-NonCommercial 3.0 (CC BY-NC 3.0) United States License.

To cite this case study please use:

Wright, Carrie and Ontiveros, Michael and Jager, Leah and Taub, Margaret and Hicks, Stephanie. (2020). https://github.com/opencasestudies/ocs-bp-RTC-wrangling. Influence of Multicollinearity on Measured Impact of Right-to-Carry Gun Laws Part 1 (Version v1.0.0).

To access the GitHub repository for this case study see here: https://github.com/opencasestudies/ocs-bp-RTC-wrangling.
This case study is part of a series of public health case studies for the Bloomberg American Health Initiative.
See this case study for part 2 which includes a data analysis and information about data visualization.

Please help us by filling out our survey.

Motivation


This case study shows the wrangling performed for another case study.

This other case study introduces the topic of multicollinearity, which occurs in regression when one or more independent variables can be predicted by other independent variables.

It does so by showcasing a real world example where multicollinearity in part resulted in historically controversial and conflicting findings about the influence of the adoption of right-to-carry (RTC) concealed handgun laws on violent crime rates in the United States.

We will focus on two articles:

  1. The first analysis by Mustard and Lott published in 1996 suggests that RTC laws reduce violent crime. Lott authored a book extending these findings in 1998 called More Guns, Less Crime.

[source]
  1. The second analysis is a recent article by Donohue, et al. published in 2017 that suggests that RTC laws increase violent crime. Donohue has also published previous articles with titles such as Shooting down the “More Guns, Less Crime” Hypothesis.

[source]

This has been a controversial topic as many other analyses also produced conflicting results. See here for a list of studies.

The Donohue, et al. article discusses how there are many other important methodological aspects besides multicollinearity (which occurs when predictor or input variables are highly related in a regression analysis) that could account for the historically conflicting results in these previous manuscripts.

In fact, nearly every aspect of the data analysis process was different between the Donohue, et al. and Mustard and Lott analyses.

However, we will focus particularly on multicollinearity and how it can influence the results we get from linear regression. Specifically, this analysis will demonstrate how methodological details can be critically influential for our overall conclusions and can result in important policy related consequences. The Donohue, et al. article will provide a basis for the motivation.

John J. Donohue et al., Right‐to‐Carry Laws and Violent Crime: A Comprehensive Assessment Using Panel Data and a State‐Level Synthetic Control Analysis. Journal of Empirical Legal Studies, 16,2 (2019).

David B. Mustard & John Lott. Crime, Deterrence, and Right-to-Carry Concealed Handguns. Coase-Sandor Institute for Law & Economics Working Paper No. 41, (1996).

Before we leave this section, we provide a high-level overview of what variables were (or were not) included in the Donohue, Aneja and Weber) (DAW) paper and the Mustard and Lott (ML) paper:

[source]
*ML is abbreviated as LM in the source article

Note: We are not attempting to re-create the analyses from the original authors. Instead, we aim to use a subset of the listed explanatory variables in this case study to demonstrate multicollinearity. These variables will be consistent for both analyses that we will perform, with the exception that one analysis will have 6 demographic variables as in the analysis in the Donohue, et al. article and the other will have 36 demographic variables, grouping individuals into more specific categories, as in the analysis in the Mustard and Lott article.

Main Question


Our main question:

What is the effect of multicollinearity on coefficient estimates from linear regression models when analyzing right to carry laws and violence rates?

Specifically, we will consider the two ways to define the demographic variables (as described above) and investigate how the inclusion of different numbers of age groups influences the results of an analysis of right to carry laws and violence rates

In this case study we only demonstrate how to import and wrangle the data.

Learning Objectives


Data Science Learning Objectives:

  1. Data import of many different file types with special cases (readr, readxl, pdftools)
  2. Joining data from multiple sources (dplyr)
  3. Working with character strings (stringr)
  4. Data comparisons (dplyr and janitor)
  5. Reshaping data into different formats (tidyr)

We will especially focus on using packages and functions from the tidyverse, such as dplyr and ggplot2. The tidyverse is a library of packages created by RStudio. While some students may be familiar with previous R programming packages, these packages make data science in R especially legible.

Context


So what exactly is a right-to-carry law?

It is a law that specifies if and how citizens are allowed to have a firearm on their person or nearby (for example, in a citizen’s car) in public.

The Second Amendment to the United States Constitution guarantees the right to “keep and bear arms”. The amendment was ratified in 1791 as part of the Bill of Rights.