robincar_linear.Rd
Estimate treatment-group-specific response means and (optionally) treatment group contrasts using a linear working model for continuous outcomes.
robincar_linear(
df,
treat_col,
response_col,
car_strata_cols = NULL,
covariate_cols = NULL,
car_scheme = "simple",
adj_method = "ANOVA",
contrast_h = NULL,
contrast_dh = NULL
)
A data.frame with the required columns
Name of column in df with treatment variable
Name of the column in df with response variable
Names of columns in df with car_strata variables
Names of columns in df with covariate variables. **If you want to include the strata variables as covariates also, add them here.**
Name of the type of covariate-adaptive randomization scheme. One of: "simple", "pocock-simon", "biased-coin", "permuted-block".
Name of linear adjustment method to use. One of: "ANOVA", "ANCOVA", "ANHECOVA".
An optional function to specify a desired contrast
An optional jacobian function for the contrast (otherwise use numerical derivative)
See value of RobinCar::robincar_glm(), this function is a wrapper using a linear link function.
* Adjustment method "ANOVA" fits a linear model with formula `Y ~ A` where `A` is the treatment group indicator and `Y` is the response. * "ANCOVA" fits a linear model with `Y ~ A + X` where `X` are the variables specified in the `covariate_cols` argument. * "ANHECOVA" fits a linear model with `Y ~ A*X`, the main effects and treatment-by-covariate interactions.