highmlr_conformal: Conformal prediction intervals for survival times

View source: R/conformal.R

highmlr_conformalR Documentation

Conformal prediction intervals for survival times

Description

Computes calibrated lower bounds on survival time for each new subject using a split-conformal procedure with inverse probability of censoring weights (Candes, Lei and Ren, 2023). The returned lower bound satisfies a marginal coverage guarantee approximately equal to one minus alpha under standard conformal assumptions and a consistent censoring model.

Usage

highmlr_conformal(
  fit,
  new_data,
  calibration_data = NULL,
  alpha = 0.1,
  calibration_split = 0.3,
  time = NULL,
  status = NULL,
  seed = NULL
)

Arguments

fit

A highmlr_fit object whose predict() method returns a linear predictor or risk score.

new_data

Data frame on which to compute prediction intervals.

calibration_data

Data frame on which to compute conformity scores. If NULL, a random calibration_split fraction of new_data is held out for calibration and the rest is used as the test set (split-conformal).

alpha

Miscoverage level; default 0.1 (so 90 percent coverage).

calibration_split

Fraction of new_data to use for calibration when calibration_data is NULL. Default 0.3.

time

Name of the survival time column in calibration data. Defaults to the column used in fit.

status

Name of the event column in calibration data.

seed

Optional integer seed for the split.

Value

An object of class highmlr_conformal containing per-subject point predictions and lower confidence bounds for survival time.

Examples

## Not run: 
fit  <- highmlr(d_train, "OS", "Death", method = "coxnet")
intv <- highmlr_conformal(fit, new_data = d_test, alpha = 0.1)
print(intv)
plot(intv)

## End(Not run)


highMLR documentation built on May 23, 2026, 5:07 p.m.