mrd_est: Multivariate Regression Discontinuity Estimation

Description Usage Arguments Value References Examples

Description

mrd_est estimates treatment effects in an MRDD with two assignment variables, including the frontier average treatment effect (tau_MRD) and frontier-specific effects (tau_R and tau_M) simultaneously.

Usage

1
2
3
4
5
6
mrd_est(formula, data, subset = NULL, cutpoint = NULL, bw = NULL,
  kernel = "triangular", se.type = "HC1", cluster = NULL,
  verbose = FALSE, less = FALSE, est.cov = FALSE, est.itt = FALSE,
  local = 0.15, ngrid = 250, margin = 0.03, boot = NULL,
  method = c("center", "univ", "front"), t.design = NULL,
  stop.on.error = TRUE)

Arguments

formula

The formula of the MRDD. This is supplied in the format of y ~ x1 + x2 for a simple sharp MRDD, or y ~ x1 + x2 | c1 + c2 for a sharp MRDD with two covariates. Fuzzy MRDD may be specified as y ~ x1 + x2 + z where x is the running variable, and z is the endogenous treatment variable. Covariates are then included in the same manner as in a sharp MRDD.

data

An optional data frame.

subset

An optional vector specifying a subset of observations to be used.

cutpoint

The cutpoint. If omitted, it is assumed to be c(0, 0).

bw

A numeric vector specifying the bandwidths at which to estimate the RD. If omitted or it is "IK12", the bandwidth is calculated using the Imbens-Kalyanaraman 2012 method. If it is "IK09", the bandwidth is calculated using the Imbens-Kalyanaraman 2009 method. Then it is estimated with that bandwidth, half that bandwidth, and twice that bandwidth. If only a single value is passed into the function, the RD will similarly be estimated at that bandwidth, half that bandwidth, and twice that bandwidth.

kernel

A string specifying the kernel to be used in the local linear fitting. "triangular" kernel is the default and is the "correct" theoretical kernel to be used for edge estimation as in RDD (Lee and Lemieux, 2010). Other options are "rectangular", "epanechnikov", "quartic", "triweight", "tricube", "gaussian" and "cosine".

se.type

This specifies the robust SE calculation method to use. Options are, as in vcovHC, "HC3", "const", "HC", "HC0", "HC1", "HC2", "HC4", "HC4m", "HC5". This option is overridden by cluster.

cluster

An optional vector specifying clusters within which the errors are assumed to be correlated. This will result in reporting cluster robust SEs. This option overrides anything specified in se.type. It is suggested that data with a discrete running variable be clustered by each unique value of the running variable (Lee and Card, 2008).

verbose

Will provide some additional information printed to the terminal.

less

Logical. If TRUE, return the estimates of linear and optimal, instead of linear, quadratic, cubic, optimal, half and double.

est.cov

Logical. If TRUE, the estimates of covariates will be included.

est.itt

Logical. If TRUE, the estimates of ITT will be returned.

local

The range of neighboring points around the cutoff on the standardized scale on each assignment variable, which is a positive number.

ngrid

The number of non-zero grid points on each assignment variable, which is also the number of zero grid points on each assignment variable. Value used in Wong, Steiner and Cook (2013) is 2500, which may cause long computational time.

margin

The range of grid points beyond the minimum and maximum of sample points on each assignment variable.

boot

The number of bootstrap samples to obtain standard error of estimates.

method

The method to estimate rd effect. Options are "center", "univ", "front".

t.design

The treatment option according to design. The 1st entry is for X1: "g" means treatment is assigned if X1 is greater than its cutoff, "geq" means treatment is assigned if X1 is greater than or equal to its cutoff, "l" means treatment is assigned if X1 is less than its cutoff, "leq" means treatment is assigned if X1 is less than or equal to its cutoff. The 2nd entry is for X2.

stop.on.error

Logical. If TRUE (the default), removes bootstraps which cause error in the integrate function, and resample till the specified number of bootstrap samples are acquired.

Value

mrd_est returns an object of class "mrd".

References

Wong, V. C., Steiner, P. M., Cook, T. D. (2013). Analyzing regression-discontinuity designs with multiple assignment variables: A comparative study of four estimation methods. Journal of Educational and Behavioral Statistics, 38(2), 107-141. http://journals.sagepub.com/doi/10.3102/1076998611432172.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
x1 <- runif(1000, -1, 1)
x2 <- runif(1000, -1, 1)
cov <- rnorm(1000)
y <- 3 + 2 * (x1 >= 0) + 3 * cov + 10 * (x2 >= 0) + rnorm(1000)
# centering
mrd_est(y ~ x1 + x2 | cov, method = "center", t.design = c("geq", "geq"))
# univariate
mrd_est(y ~ x1 + x2 | cov, method = "univ", t.design = c("geq", "geq"))
# frontier
mrd_est(y ~ x1 + x2 | cov, method = "front", t.design = c("geq", "geq"))

Example output

$center
$center$tau_MRD

Call:
rd_est(formula = Y ~ X | cov, data = data, subset = NULL, cutpoint = 0, 
    bw = bw, kernel = "triangular", se.type = se.type, cluster = cluster, 
    verbose = verbose, less = less, est.cov = est.cov, est.itt = FALSE, 
    t.design = "leq")

Coefficients:
    Linear   Quadratic       Cubic         Opt    Half-Opt  Double-Opt  
     6.806       6.643       5.384       6.766       6.342       6.792  



$call
mrd_est(formula = y ~ x1 + x2 | cov, method = "center", t.design = c("geq", 
    "geq"))

attr(,"class")
[1] "mrd"
$univ
$univ$tau_R

Call:
rd_est(formula = Y ~ X1 | cov, data = data, subset = subset1, 
    cutpoint = 0, bw = NULL, kernel = "triangular", se.type = se.type, 
    cluster = cluster, verbose = verbose, less = less, est.cov = est.cov, 
    est.itt = FALSE, t.design = "geq")

Coefficients:
    Linear   Quadratic       Cubic         Opt    Half-Opt  Double-Opt  
     2.200       2.108       2.280       2.198       2.035       2.194  


$univ$tau_M

Call:
rd_est(formula = Y ~ X2 | cov, data = data, subset = subset2, 
    cutpoint = 0, bw = NULL, kernel = "triangular", se.type = se.type, 
    cluster = cluster, verbose = verbose, less = less, est.cov = est.cov, 
    est.itt = FALSE, t.design = "geq")

Coefficients:
    Linear   Quadratic       Cubic         Opt    Half-Opt  Double-Opt  
     10.51       10.57       10.90       10.59       10.77       10.52  



$call
mrd_est(formula = y ~ x1 + x2 | cov, method = "univ", t.design = c("geq", 
    "geq"))

attr(,"class")
[1] "mrd"
$front
$front$tau_MRD

Call:
mfrd_est(y = Y, x1 = X1, x2 = X2, c1 = 0, c2 = 0, t.design = c("geq", 
"geq"), local = 0.15, ngrid = ngrid, margin = margin, boot = boot, 
    cluster = cluster, stop.on.error = stop.on.error)

Coefficients:
   ev1     ev2     ate   htev1   htev2   htate    tev1    tev2    tate  
 1.781  10.621   5.821   1.948  10.661   5.931   3.837   3.837   3.837  



$call
mrd_est(formula = y ~ x1 + x2 | cov, method = "front", t.design = c("geq", 
    "geq"))

attr(,"class")
[1] "mrd"

rddapp documentation built on May 1, 2019, 8:04 p.m.