plotBalance {polymatching} | R Documentation |
Summary Plot of Balance in Covariates
Description
The function generates a plot summarizing the balance of the covariates.
Usage
plotBalance(dataBalance, ratioVariances = FALSE, boxplots = TRUE)
Arguments
dataBalance |
the output of |
ratioVariances |
Boolean. If |
boxplots |
Boolean. If |
Value
If at least one of the covariates is continuous and ratioVariances=TRUE
,
the function generates a plot with two panels: one for the
standardized differences and one for the ratio of the variances (only for the continous variables).
If either all the covariates are categorical/binary or ratioVariances=FALSE
(or both),
only the plot with the standardized differences is generated.
The function also returns a list with the ggplot2
objects corresponding to the generated plot(s).
See Also
polymatch
to generate matched samples and balance
to compute
the indicators of balance.
Examples
#See examples of function 'balance'