get_difference: Calculate the difference in the mean of the metric for two...

View source: R/compare_models.R

get_differenceR Documentation

Calculate the difference in the mean of the metric for two groups

Description

Calculate the difference in the mean of the metric for two groups

Usage

get_difference(sub_data, group_name, metric)

Arguments

sub_data

subset of the merged performance data frame for two groups

group_name

name of column with group variable

metric

metric to compare

Value

numeric difference in the average metric between the two groups

Author(s)

Courtney Armour, armourc@umich.edu

Examples

## 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)

SchlossLab/mikropml documentation built on Aug. 24, 2023, 9:51 p.m.