pintervals1.0.1 package

Model Agnostic Prediction Intervals

abs_error

Absolute Error Function for Non-Conformity Scores

bcss_compute

Function to compute the between-cluster sum of squares (BCSS) for a se...

bin_chopper

Bin chopper function for binned bootstrapping

bindividual_alpha

Bin-individual alpha function for conformal prediction

bootstrap_inner

Bootstrap function for bootstrapping the prediction intervals

cauchy_kern

Cauchy Kernel Function

ch_index

Function to compute the Calinski-Harabasz index for a set of clusters

class_to_clusters

Function to convert class vector to cluster vector based on calibrated...

clusterer

Function to cluster non-conformity scores using either Kolmogorov-Smir...

contiguize_intervals

Contiguize non-contiguous intervals

coverage_gap_finder

Function to find the coverage gap for a set of clusters

Dm_finder

Function to find the minimum distance between a class and a set of clu...

dm_to_prob

Function to convert distance measure to probability

flatten_cp_bin_intervals

Flatten binned conformal prediction intervals to contiguous intervals

gauss_kern

Gaussian Kernel Function

grid_finder

Grid search for lower and upper bounds of continuous conformal predict...

grid_inner

Inner function for grid search

heterogeneous_error

Heterogeneous Error Function for Non-Conformity Scores

interval_coverage

Empirical coverage of prediction intervals

interval_miscoverage

Empirical miscoverage of prediction intervals

interval_score

Mean interval score (MIS) for prediction intervals

interval_width

Mean width of prediction intervals

kmeans_cluster_qecdf

Function to perform K-means clustering on quantile empirical cumulativ...

ks_cluster_assignment_step

Function to assign classes to clusters based on Kolmogorov-Smirnov clu...

ks_cluster_init_step

Function to initialize clusters for Kolmogorov-Smirnov clustering

ks_cluster

Function to perform Kolmogorov-Smirnov clustering on non-conformity sc...

logistic_kern

Logistic Kernel Function

minq_to_alpha

Helper for minimum quantile to alpha function

ncs_compute

Non-Conformity Score Computation Function

optimize_clusters

Function to optimize clusters based on the Calinski-Harabasz index

pinterval_bccp

Bin-conditional conformal prediction intervals for continuous predicti...

pinterval_bootstrap

Bootstrap prediction intervals

pinterval_ccp

Clustered conformal prediction intervals for continuous predictions

pinterval_conformal

Conformal Prediction Intervals of Continuous Values

pinterval_mondrian

Mondrian conformal prediction intervals for continuous predictions

pinterval_parametric

#' Parametric prediction intervals for continuous predictions

pintervals-package

pintervals: Model Agnostic Prediction Intervals

raw_error

Raw Error Function for Non-Conformity Scores

reciprocal_linear_kern

Reciprocal Linear Kernel Function

rel_error

Relative Error Function for Non-Conformity Scores by predicted Values

wcss_compute

Function to compute the within-cluster sum of squares (WCSS) for a set...

za_rel_error

Zero-adjusted Relative Error Function for Non-Conformity Scores by pre...

Provides tools for estimating model-agnostic prediction intervals using conformal prediction, bootstrapping, and parametric prediction intervals. The package is designed for ease of use, offering intuitive functions for both binned and full conformal prediction methods, as well as parametric interval estimation with diagnostic checks. Currently only working for continuous predictions. For details on the conformal and bin-conditional conformal prediction methods, see Randahl, Williams, and Hegre (2024) <DOI:10.48550/arXiv.2410.14507>.

  • Maintainer: David Randahl
  • License: GPL (>= 3)
  • Last published: 2026-01-11