Paired DeLong SE for single-sample AUC lift
Source:R/singlesample-paired-auc-diff-se.R
singlesample_paired_auc_diff_se.RdComputes the empirical DeLong variance of a paired AUC difference (method score minus baseline score). When `fold` is supplied, the per-fold DeLong variances are aggregated as the variance of the mean fold-level AUC difference, matching the `auc_obs_cv = mean(auc_obs_folds)` mean-of-folds estimand.
Usage
singlesample_paired_auc_diff_se(
y,
score_method,
score_baseline,
fold = NULL,
orient = c("fixed", "median", "auc")
)Arguments
- y
Binary outcome vector, coded 0/1 or a two-level factor.
- score_method
Numeric scores from the candidate method.
- score_baseline
Numeric scores from the paired baseline method.
- fold
Optional fold identifier. If `NULL`, all observations are treated as one fold.
- orient
Orientation rule. The default, `"fixed"`, preserves the supplied score direction and therefore does not inspect held-out outcomes to choose orientation. `"median"` mirrors pROC's within-cohort auto-orientation convention; `"auc"` reports `max(AUC, 1 - AUC)` and is retained as an explicit opt-in for sign-invariant descriptive analyses.