balance_regression {RCT} | R Documentation |
balance_regression() Runs a LPM of treatment status against all covariates (treatment~X'B).
Description
balance_regression() Runs a LPM of treatment status against all covariates (treatment~X'B).
Usage
balance_regression(data, treatment)
Arguments
data |
A data.frame, tibble or data.table |
treatment |
a string with treatment status column |
Details
This functions runs a Linear Probability model of each treatment group & control on all the columns in data. For instance, if treatment column has values of (0,1,2), balance_regression will run two models: 1) LPM(treatment(0,1)~X'b) and 2) LPM(treatment(0,2)~X'b). The value are the regression tables and details of the F_test of these models.
Value
A list: regression_tables = regression output of treatment against all covariates, F_test = table with the F tests of each regression
Examples
data <-data.frame(x1 = rnorm(n = 100, mean = 100, sd = 15), x2= rnorm(n = 100, mean = 65),
treat = rep(c(0,1,2,3,4), each = 20))
balance_regression(data = data, treatment = "treat")
[Package RCT version 1.2 Index]