ranked_balances {groupdata2}R Documentation

Extract ranked standard deviations from summary

Description

[Experimental]

Extract the standard deviations (default) from the "Summary" data.frame from the output of summarize_balances(), ordered by the `SD_rank` column.

See examples of usage in summarize_balances().

Usage

ranked_balances(summary, measure = "SD")

Arguments

summary

"Summary" data.frame from output of summarize_balances().

Can also be the direct output list of summarize_balances(), in which case the "Summary" element is used.

measure

The measure to extract rows for. One of: "mean", "median", "SD", "IQR", "min", "max".

The most meaningful measures to consider as metrics of balance are `SD` and `IQR`, as a smaller spread of variables across group summaries means they are more similar.

NOTE: Ranks are of standard deviations and not affected by this argument.

Value

The rows in `summary` where `measure` == "SD", ordered by the `SD_rank` column.

Author(s)

Ludvig Renbo Olsen, r-pkgs@ludvigolsen.dk

See Also

Other summarization functions: summarize_balances(), summarize_group_cols()


[Package groupdata2 version 2.0.3 Index]