Quasi Experiments and Regression Discontinuity Designs

Zahid Asghar

12/16/2020

Outline

Quasi-Experiments

In a quasi-experiment, also called a natural experiment, randomness is introduced by variation in individual circumstances that makes it appear as if the treatment is randomly assigned.

timing of policy or programimplementation, natural randomness such as birth dates, rainfall, or other that are

unrelated to the causeal effect under study. There are two types of quasi-experiments.

Two types of quasi-experiments

Examples

Labour market effects of immigration

In this first example of quasi-experiment the treament is “as if” randomly determined. - Does immigration reduces wages? Eco Th: if supply of labour increases as wages increases. However, if all else equal, immigrants are attracted to cities with higher demand so OLS estimators of effect on wages of immigration are biased. - Randomized experiment not ethical/feasible

Example 2 : Effects on civilian earnings of military Service

In this case “as if” influences but not entirely random. - Does serving in the military improve your prospects on the labor market?

Example 3 : Effect of Catheterization

Many other example of quasi-experiments in the field of economics and social policy. Quasi-experiments provide a bridge between observational data sets and true randomized controlled experiments

Regression Discontinuity Designs (RDD)

When randomization is not feasible, how can we exploit implementation features of the program to measure its impact? - Answer: Quasi-experiments - Example: Regression Discontinuity Design.

Types of RDD

Sharp Designs

# generate some sample data
W <- runif(1000, -1, 1)
y <- 3 + 2 * W + 10 * (W>=0) + rnorm(1000)
# load the package 'rddtools'
library(rddtools)

# construct rdd_data 
data <- rdd_data(y, W, cutpoint = 0)

# plot the sample data

plot(data,
     col = "steelblue",
     cex = 0.35, 
     xlab = "W", 
     ylab = "Y")

library(ggplot2)
ggplot(data)+aes(x=W,y=y)+geom_point()

# estimate the sharp RDD model
rdd_mod <- rdd_reg_lm(rdd_object = data, 
                      slope = "same")
summary(rdd_mod)
## 
## Call:
## lm(formula = y ~ ., data = dat_step1, weights = weights)
## 
## Residuals:
##      Min       1Q   Median       3Q      Max 
## -2.93158 -0.65069 -0.00315  0.67454  2.83645 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  3.02887    0.06909   43.84   <2e-16 ***
## D            9.98935    0.12465   80.14   <2e-16 ***
## x            1.97863    0.10861   18.22   <2e-16 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.9964 on 997 degrees of freedom
## Multiple R-squared:  0.9732, Adjusted R-squared:  0.9732 
## F-statistic: 1.812e+04 on 2 and 997 DF,  p-value: < 2.2e-16
# plot the RDD model along with binned observations
plot(rdd_mod,
     cex = 0.35, 
     col = "steelblue", 
     xlab = "W", 
     ylab = "Y")

Fuzzy Designs

library(MASS)
# generate sample data
mu <- c(0, 0)
sigma <- matrix(c(1, 0.7, 0.7, 1), ncol = 2)

set.seed(1234)
d <- as.data.frame(mvrnorm(2000, mu, sigma))
colnames(d) <- c("W", "Y")

# introduce fuzziness
d$treatProb <- ifelse(d$W < 0, 0, 0.8)

fuzz <- sapply(X = d$treatProb, FUN = function(x) rbinom(1, 1, prob = x))

# treatment effect
d$Y <- d$Y + fuzz * 2
# generate a colored plot of treatment and control group
plot(d$W, d$Y,
     col = c("steelblue", "darkred")[factor(fuzz)], 
     pch= 20, 
     cex = 0.5,
     xlim = c(-3, 3),
     ylim = c(-3.5, 5),
     xlab = "W",
     ylab = "Y")
# add a dashed vertical line at cutoff
abline(v = 0, lty = 2)

For more on these codes you can read Ch.13 Introduction to Econometrics with R