preprocess | R Documentation |
Function to preprocess the data and obtain the design matrices corresponding to a model with just interaction of the covariates with the treatment, to a model with just the main effects and to a model just with the covariates and one-hot encoding.
preprocess(trt, subgr, covars, data)
trt |
( |
subgr |
( |
covars |
( |
data |
( |
List with design_ia
, design_main
, design_dummy
, subgr_names
.
preprocess("arm", c("x_1", "x_2"), c("x_1", "x_2", "x_3"), example_data)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.