Skip to contents

Routes to the native balance engine (morie_matching_balance): standardized mean differences and variance ratios before/after weighting, plus the effective sample size.

Usage

morie_weight_diagnostic(w, data, treatment, covariates)

Arguments

w

A morie_weight object.

data, treatment, covariates

The inputs the weights were built from.

Value

A data.frame of balance statistics with attribute ess.

Examples

set.seed(1)
d <- data.frame(t = rbinom(100, 1, 0.4), x = rnorm(100))
morie_weight_diagnostic(morie_weight_ps(d, "t", "x"), d, "t", "x")
#>   covariate mean_treated mean_control          smd      abs_smd variance_ratio
#> 1         x  -0.01711956  -0.01728272 0.0001723863 0.0001723863       1.063472
#>     ks_stat ks_p_value
#> 1 0.1488965         NA