Skip to contents

Compute covariate balance before and after adjustment with the propensity scores.

Usage

computeCovariateBalance(
  population,
  cohorts,
  covariates,
  covariateRef,
  subgroupCovariateId = NULL
)

Arguments

population

A data frame containing the people that are remaining after matching and/or trimming.

cohorts

The cohorts of a CohortMethodData object.

covariates

The covariates of a CovariateData object.

covariateRef

The covariate reference of a CovariateData object.

subgroupCovariateId

Optional: a covariate ID of a binary covariate that indicates a subgroup of interest. Both the before and after populations will be restricted to this subgroup before computing covariate balance.

Value

A tibble with the covariate balance before and after matching/trimming.