This function performs a balance assessment between treated and control groups using Seemingly Unrelated Regression (SUR) and Hotelling's T-squared test.

balance_assessment(data, treatment_col, ...)

Arguments

data

A dataframe containing the data to be assessed.

treatment_col

The name of the column that contains the treatment indicator (0 for control, 1 for treated).

...

Names of the dependent variables.

Value

A list with two elements: 'SUR' (results of the SUR) and 'Hotelling' (results of the Hotelling's T-squared test).

Examples

if (FALSE) {
set.seed(123)
data = mtcars %>% 
  dplyr::select(mpg, cyl, disp, hp, wt) %>% 
  dplyr::rowwise() %>% 
  dplyr::mutate(treatment = sample(c(0,1), 1, replace = TRUE)) %>% 
  dplyr::ungroup()

results <- balance_assessment(data, "treatment", "mpg", "cyl")
print(results$SUR)
print(results$Hotelling)
}