rddapp (version 1.1.0)

mrd_impute: Multiple Imputation of Multivariate Regression Discontinuity Estimation

Description

mrd_impute estimates treatment effects in an MRDD with imputed missing values.

Usage

mrd_impute(formula, data, subset = NULL, cutpoint = NULL, bw = NULL,
  kernel = "triangular", se.type = "HC1", cluster = NULL, impute = NULL,
  verbose = FALSE, less = FALSE, est.cov = FALSE, est.itt = FALSE,
  local = 0.15, ngrid = 2500, margin = 0.03, boot = NULL,
  method = c("center", "univ", "front"), t.design = NULL)

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 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).

impute

An optional vector specifying the imputed variables with missing values.

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.

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 deviation 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.

Value

rd_impute returns an object of class "mrd".

References

Stata: 64 mi estimate - Estimation using multiple imputations

Examples

Run this code
# NOT RUN {
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)
group <- rep(1:10, each = 100)
# centering
mrd_impute(y ~ x1 + x2 | cov, impute = group, method = "center", t.design = c("geq", "geq"))
# univariate
mrd_impute(y ~ x1 + x2 | cov, impute = group, method = "univ", t.design = c("geq", "geq"))
# frontier
mrd_impute(y ~ x1 + x2 | cov, impute = group, method = "front", t.design = c("geq", "geq"))
# }

Run the code above in your browser using DataLab