View source: R/compare_models.R
get_difference | R Documentation |
Calculate the difference in the mean of the metric for two groups
get_difference(sub_data, group_name, metric)
sub_data |
subset of the merged performance data frame for two groups |
group_name |
name of column with group variable |
metric |
metric to compare |
numeric difference in the average metric between the two groups
Courtney Armour, armourc@umich.edu
## Not run:
df <- dplyr::tibble(
condition = c("a", "a", "b", "b"),
AUC = c(.2, 0.3, 0.8, 0.9)
)
get_difference(df, "condition", "AUC")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.