intervals function

Computation of prediction intervals from a trained ENNreg model

Computation of prediction intervals from a trained ENNreg model

intervals computes probabilistic and belief prediction intervals from a prediction object returned by function predict.ENNreg.

intervals(pred, level = 0.9, yt = NULL)

Arguments

  • pred: Prediction object returned by function predict.ENNreg.
  • level: Level of the prediction interval (between 0 and 1).
  • yt: Optional vector of test response values.

Returns

A list with four elements:

  • INTP: Matrix (n,2) of probabilistic prediction intervals.
  • INTBel: Matrix (n,2) of belief prediction intervals.
  • coverage.P: Estimated coverage rate of the probabilistic intervals (if yt is provided).
  • coverage.Bel: Estimated coverage rate of the belief intervals (if yt is provided).
  • Pl.Bel: Mean plausibility of the belief intervals.

Examples

library(MASS) X<-as.matrix(scale(Boston[,1:13])) y<-Boston[,14] set.seed(220322) n<-nrow(Boston) ntrain<-round(0.7*n) train <-sample(n,ntrain) fit <- ENNreg(X[train,],y[train],K=30) pred<-predict(fit,newdata=X[-train,],yt=y[-train]) int<- intervals(pred,level=0.95,y[-train]) print(c(int$coverage.P,int$coverage.Bel))

See Also

predict.ENNreg, ENNreg

  • Maintainer: Thierry Denoeux
  • License: GPL-3
  • Last published: 2024-05-09

Useful links