unsup_double_conformal: Unsupervised double conformal method

View source: R/unsup_double_conformal.R

unsup_double_conformalR Documentation

Unsupervised double conformal method

Description

Take the following steps to construct the double conformal prediction interval:

  1. Apply order statistic method to each of the k groups to get k intervals [l_1, u_1], ..., [l_k, u_k] each at level 1-alpha/2. l_1 is the floor((n + 1) * alpha/4) order statistic of the first sample, u_1 is the ceiling((n + 1)*(1 - alpha/4)) order statistic of the first sample, and so on for the other samples.

  2. Consider (l_1, ..., l_k). Take l_(r), where r = floor((k + 1) * alpha/4). Consider (u_1, ..., u_k). Take u_(s), where s = ceiling((k + 1)*(1 - alpha/4)). The final prediction interval is C = [l_(r), u_(s)].

Usage

unsup_double_conformal(Y, alpha, n_val, new_Y = NULL)

Arguments

Y

List containing data of all subjects. Each item in the list is a vector with one subject's observations.

alpha

Significance level

n_val

Number of observations from each subject. For this method, we assume equal number of observations across subjects.

new_Y

Observation on new subject

Value

List containing prediction interval size, prediction interval lower bound, prediction interval upper bound, and whether new observation is contained inside prediction interval.


RobinMDunn/ConformalTwoLayer documentation built on March 22, 2022, 6:38 p.m.