rd_assumption_tests.RdRuns a battery of standard robustness and assumption tests for regression discontinuity designs: density continuity (McCrary/rddensity), covariate balance at the cutoff, bandwidth sensitivity, placebo cutoffs, and polynomial order sensitivity.
rd_assumption_tests(
data,
outcome,
running_var,
cutoff = 0,
covariates = NULL,
bw_seq = c(0.5, 0.75, 1, 1.25, 1.5),
placebo_cutoffs = NULL,
poly_orders = 1:4,
kernel = "triangular",
verbose = TRUE
)A data frame.
Character. Outcome variable name.
Character. Running (forcing) variable name.
Numeric. RD cutoff. Default 0.
Character vector or NULL. Covariates to test for
balance at the cutoff.
Numeric vector. Bandwidth multipliers to test in sensitivity
analysis. Default c(0.5, 0.75, 1, 1.25, 1.5).
Numeric vector or NULL. Placebo cutoff values
(should be far from cutoff). If NULL, auto-selected.
Integer vector. Polynomial orders to test. Default
1:4.
Character. RD kernel. Default "triangular".
Logical. Whether to print test results. Default TRUE.
A list with:
Output from rddensity::rddensity().
Data frame of RD estimates on each covariate.
Data frame of estimates at different bandwidths.
Data frame of placebo cutoff estimates.
Data frame of estimates by polynomial order.
Character. Text summary of all tests.