CRAN Package Check Results for Package ipred

Last updated on 2026-10-24 09:50:54 CEST.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-clang 0.9-16 10.99 127.74 138.73 OK
r-devel-linux-x86_64-debian-gcc 0.9-16 8.44 89.57 98.01 ERROR
r-devel-linux-x86_64-fedora-clang 0.9-16 10.00 110.60 120.60 OK
r-devel-linux-x86_64-fedora-gcc 0.9-16 92.69 OK
r-devel-windows-x86_64 0.9-16 17.00 215.00 232.00 OK
r-patched-linux-x86_64 0.9-16 11.11 113.21 124.32 OK
r-release-linux-x86_64 0.9-16 10.18 111.49 121.67 OK
r-release-macos-arm64 0.9-16 3.00 34.00 37.00 OK
r-release-macos-x86_64 0.9-16 9.00 130.00 139.00 OK
r-release-windows-x86_64 0.9-16 17.00 146.00 163.00 OK
r-oldrel-macos-arm64 0.9-16 3.00 36.00 39.00 OK
r-oldrel-macos-x86_64 0.9-16 9.00 118.00 127.00 OK
r-oldrel-windows-x86_64 0.9-16 21.00 169.00 190.00 OK

Check Details

Version: 0.9-16
Check: examples
Result: ERROR Running examples in ‘ipred-Ex.R’ failed The error most likely occurred in: > base::assign(".ptime", proc.time(), pos = "CheckExEnv") > ### Name: bagging > ### Title: Bagging Classification, Regression and Survival Trees > ### Aliases: bagging ipredbagg ipredbagg.factor ipredbagg.integer > ### ipredbagg.numeric ipredbagg.Surv ipredbagg.default bagging.data.frame > ### bagging.default > ### Keywords: tree > > ### ** Examples > > > library("MASS") > library("survival") > > # Classification: Breast Cancer data > > data("BreastCancer", package = "mlbench") > > # Test set error bagging (nbagg = 50): 3.7% (Breiman, 1998, Table 5) > > mod <- bagging(Class ~ Cl.thickness + Cell.size + + Cell.shape + Marg.adhesion + + Epith.c.size + Bare.nuclei + + Bl.cromatin + Normal.nucleoli + + Mitoses, data=BreastCancer, coob=TRUE) > print(mod) Bagging classification trees with 25 bootstrap replications Call: bagging.data.frame(formula = Class ~ Cl.thickness + Cell.size + Cell.shape + Marg.adhesion + Epith.c.size + Bare.nuclei + Bl.cromatin + Normal.nucleoli + Mitoses, data = BreastCancer, coob = TRUE) Out-of-bag estimate of misclassification error: 0.0381 > > # Test set error bagging (nbagg=50): 7.9% (Breiman, 1996a, Table 2) > data("Ionosphere", package = "mlbench") > Ionosphere$V2 <- NULL # constant within groups > > bagging(Class ~ ., data=Ionosphere, coob=TRUE) Bagging classification trees with 25 bootstrap replications Call: bagging.data.frame(formula = Class ~ ., data = Ionosphere, coob = TRUE) Out-of-bag estimate of misclassification error: 0.0969 > > # Double-Bagging: combine LDA and classification trees > > # predict returns the linear discriminant values, i.e. linear combinations > # of the original predictors > > comb.lda <- list(list(model=lda, predict=function(obj, newdata) + predict(obj, newdata)$x)) > > # Note: out-of-bag estimator is not available in this situation, use > # errorest > > mod <- bagging(Class ~ ., data=Ionosphere, comb=comb.lda) > > predict(mod, Ionosphere[1:10,]) [1] good bad good bad good bad good bad good bad Levels: bad good > > # Regression: > > data("BostonHousing", package = "mlbench") > > # Test set error (nbagg=25, trees pruned): 3.41 (Breiman, 1996a, Table 8) > > mod <- bagging(medv ~ ., data=BostonHousing, coob=TRUE) > print(mod) Bagging regression trees with 25 bootstrap replications Call: bagging.data.frame(formula = medv ~ ., data = BostonHousing, coob = TRUE) Out-of-bag estimate of root mean squared error: 4.0892 > > library("mlbench") > learn <- as.data.frame(mlbench.friedman1(200)) > > # Test set error (nbagg=25, trees pruned): 2.47 (Breiman, 1996a, Table 8) > > mod <- bagging(y ~ ., data=learn, coob=TRUE) > print(mod) Bagging regression trees with 25 bootstrap replications Call: bagging.data.frame(formula = y ~ ., data = learn, coob = TRUE) Out-of-bag estimate of root mean squared error: 2.8923 > > # Survival data > > # Brier score for censored data estimated by > # 10 times 10-fold cross-validation: 0.2 (Hothorn et al, > # 2002) > > data("DLBCL", package = "ipred") > mod <- bagging(Surv(time,cens) ~ MGEc.1 + MGEc.2 + MGEc.3 + MGEc.4 + MGEc.5 + + MGEc.6 + MGEc.7 + MGEc.8 + MGEc.9 + + MGEc.10 + IPI, data=DLBCL, coob=TRUE) Error in a$specials[[i]] : subscript out of bounds Calls: bagging ... EventHistory.frame -> model.design -> delete.response -> off Execution halted Flavor: r-devel-linux-x86_64-debian-gcc

Version: 0.9-16
Check: tests
Result: ERROR Running ‘ipred-bugs.R’ [2s/3s] Comparing ‘ipred-bugs.Rout’ to ‘ipred-bugs.Rout.save’ ... OK Running ‘ipred-segfault.R’ [4s/4s] Running ‘ipred-smalltest.R’ [2s/2s] Comparing ‘ipred-smalltest.Rout’ to ‘ipred-smalltest.Rout.save’ ... OK Running the tests in ‘tests/ipred-segfault.R’ failed. Complete output: > library("ipred") > library("mlbench") > library("MASS") > library("survival") > > suppressWarnings(RNGversion("3.5.3")) > > actversion <- paste(R.version$major, R.version$minor, sep=".") > thisversion <- "1.7.0" > > #if (compareVersion(actversion, thisversion) >= 0) { > # RNGversion("1.6.2") > #} > set.seed(29081975) > > > # Classification > > learn <- as.data.frame(mlbench.twonorm(200)) > test <- as.data.frame(mlbench.twonorm(100)) > > # bagging > > mod <- bagging(classes ~ ., data=learn, coob=TRUE, nbagg=10) > mod Bagging classification trees with 10 bootstrap replications Call: bagging.data.frame(formula = classes ~ ., data = learn, coob = TRUE, nbagg = 10) Out-of-bag estimate of misclassification error: 0.195 > predict(mod)[1:10] [1] 1 1 1 2 2 2 1 1 1 1 Levels: 1 2 > > # Double-Bagging > > comb.lda <- list(list(model=lda, predict=function(obj, newdata) + predict(obj, newdata)$x)) > > mod <- bagging(classes ~ ., data=learn, comb=comb.lda, nbagg=10) > mod Bagging classification trees with 10 bootstrap replications Call: bagging.data.frame(formula = classes ~ ., data = learn, comb = comb.lda, nbagg = 10) > predict(mod, newdata=test[1:10,]) [1] 1 1 1 1 1 2 1 2 1 2 Levels: 1 2 > predict(mod, newdata=test[1:10,], agg="aver") [1] 1 1 1 1 2 2 1 2 1 2 Levels: 1 2 > predict(mod, newdata=test[1:10,], agg="wei") [1] 1 1 1 1 2 2 1 2 1 2 Levels: 1 2 > predict(mod, newdata=test[1:10,], type="prob") 1 2 [1,] 1.0 0.0 [2,] 0.9 0.1 [3,] 1.0 0.0 [4,] 1.0 0.0 [5,] 0.5 0.5 [6,] 0.0 1.0 [7,] 1.0 0.0 [8,] 0.1 0.9 [9,] 1.0 0.0 [10,] 0.0 1.0 > predict(mod, newdata=test[1:10,], type="prob", agg="aver") 1 2 [1,] 1.0 0.0 [2,] 0.9 0.1 [3,] 1.0 0.0 [4,] 1.0 0.0 [5,] 0.5 0.5 [6,] 0.0 1.0 [7,] 1.0 0.0 [8,] 0.1 0.9 [9,] 1.0 0.0 [10,] 0.0 1.0 > predict(mod, newdata=test[1:10,], type="prob", agg="wei") 1 2 [1,] 1.000000000 0.000000000 [2,] 0.996441281 0.003558719 [3,] 1.000000000 0.000000000 [4,] 1.000000000 0.000000000 [5,] 0.484359233 0.515640767 [6,] 0.000000000 1.000000000 [7,] 1.000000000 0.000000000 [8,] 0.001138952 0.998861048 [9,] 1.000000000 0.000000000 [10,] 0.000000000 1.000000000 > > mypredict.lda <- function(object, newdata) + predict(object, newdata = newdata)$class > > errorest(classes ~ ., data=learn, model=lda, predict=mypredict.lda) Call: errorest.data.frame(formula = classes ~ ., data = learn, model = lda, predict = mypredict.lda) 10-fold cross-validation estimator of misclassification error Misclassification error: 0.035 > errorest(classes ~ ., data=learn, model=lda, predict=mypredict.lda, + est.para=control.errorest(k=5, random=FALSE)) Call: errorest.data.frame(formula = classes ~ ., data = learn, model = lda, predict = mypredict.lda, est.para = control.errorest(k = 5, random = FALSE)) 5-fold cross-validation estimator of misclassification error Misclassification error: 0.04 > > lapply(errorest(classes ~ ., data=learn, model=lda, predict=mypredict.lda, + est.para=control.errorest(k=5, random=FALSE, getmodels=TRUE))$models, class) [[1]] [1] "lda" [[2]] [1] "lda" [[3]] [1] "lda" [[4]] [1] "lda" [[5]] [1] "lda" > errorest(classes ~ ., data=learn, model=bagging, + est.para=control.errorest(k=2), nbagg=10) Call: errorest.data.frame(formula = classes ~ ., data = learn, model = bagging, est.para = control.errorest(k = 2), nbagg = 10) 2-fold cross-validation estimator of misclassification error Misclassification error: 0.12 > errorest(classes ~ ., data=learn, model=bagging, + est.para=control.errorest(k=2), nbagg=10, comb=comb.lda) Call: errorest.data.frame(formula = classes ~ ., data = learn, model = bagging, est.para = control.errorest(k = 2), nbagg = 10, comb = comb.lda) 2-fold cross-validation estimator of misclassification error Misclassification error: 0.055 > errorest(classes ~ ., data=learn, model=lda, + predict=mypredict.lda, estimator="boot") Call: errorest.data.frame(formula = classes ~ ., data = learn, model = lda, predict = mypredict.lda, estimator = "boot") Bootstrap estimator of misclassification error with 25 bootstrap replications Misclassification error: 0.038 Standard deviation: 0.0023 > errorest(classes ~ ., data=learn, model=lda, + predict=mypredict.lda, estimator="632plus") Call: errorest.data.frame(formula = classes ~ ., data = learn, model = lda, predict = mypredict.lda, estimator = "632plus") .632+ Bootstrap estimator of misclassification error with 25 bootstrap replications Misclassification error: 0.0336 > > # Regression > > learn <- as.data.frame(mlbench.friedman1(100)) > test <- as.data.frame(mlbench.friedman1(100)) > > # bagging > > mod <- bagging(y ~ ., data=learn, coob=TRUE, nbagg=10) > mod Bagging regression trees with 10 bootstrap replications Call: bagging.data.frame(formula = y ~ ., data = learn, coob = TRUE, nbagg = 10) Out-of-bag estimate of root mean squared error: 3.0773 > predict(mod)[1:10] [1] 13.367299 15.465575 10.728200 21.426540 16.379882 16.992572 NA [8] 12.899667 8.096002 16.070858 > > predict(mod, newdata=test[1:10,]) [1] 13.90686 14.94293 12.94732 11.67369 16.63664 14.42252 16.01717 12.34594 [9] 11.96764 22.14124 > predict(mod, newdata=test[1:10,], agg="aver") [1] 13.90686 14.94293 12.94732 11.67369 16.63664 14.42252 16.01717 12.34594 [9] 11.96764 22.14124 > predict(mod, newdata=test[1:10,], agg="wei") [1] 13.96527 14.95040 12.92685 11.61045 16.74963 14.59937 16.46226 12.44494 [9] 12.20556 22.00779 > errorest(y ~ ., data=learn, model=lm) Call: errorest.data.frame(formula = y ~ ., data = learn, model = lm) 10-fold cross-validation estimator of root mean squared error Root mean squared error: 2.7385 > errorest(y ~ ., data=learn, model=lm, + est.para=control.errorest(k=5, random=FALSE)) Call: errorest.data.frame(formula = y ~ ., data = learn, model = lm, est.para = control.errorest(k = 5, random = FALSE)) 5-fold cross-validation estimator of root mean squared error Root mean squared error: 2.7941 > lapply(errorest(y ~ ., data=learn, model=lm, + est.para=control.errorest(k=5, random=FALSE, getmodels=TRUE))$models, class) [[1]] [1] "lm" [[2]] [1] "lm" [[3]] [1] "lm" [[4]] [1] "lm" [[5]] [1] "lm" > errorest(y ~ ., data=learn, model=lm, estimator="boot") Call: errorest.data.frame(formula = y ~ ., data = learn, model = lm, estimator = "boot") Bootstrap estimator of root mean squared error with 25 bootstrap replications Root mean squared error: 2.7966 > > # survival > > learn <- rsurv(100, model="C") > test <- rsurv(100, model="C") > > mod <- bagging(Surv(time, cens) ~ ., data=learn, nbagg=10) > mod Bagging survival trees with 10 bootstrap replications Call: bagging.data.frame(formula = Surv(time, cens) ~ ., data = learn, nbagg = 10) > predict(mod, newdata=test[1:10,]) [[1]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 117 117 0.0751 0.064 0.123 [[2]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 134 134 0.028 0.0247 0.0321 [[3]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 142 142 0.215 0.179 0.241 [[4]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 131 131 0.0216 0.0205 0.028 [[5]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 145 145 0.217 0.168 0.251 [[6]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 105 105 0.0476 0.0421 0.0496 [[7]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 125 125 0.181 0.156 0.218 [[8]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 139 139 0.179 0.156 0.217 [[9]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 131 131 0.181 0.179 0.251 [[10]] Call: survfit(formula = Surv(agglsample[[j]], aggcens[[j]]) ~ 1) n events median 0.95LCL 0.95UCL [1,] 120 120 0.028 0.0247 0.0395 > > #errorest(Surv(time, cens) ~ ., data=learn, model=bagging, > # est.para=list(k=2, random=FALSE), nbagg=5) > #errorest(Surv(time, cens) ~ ., data=learn, model=bagging, > # estimator="boot", nbagg=5, est.para=list(nboot=5)) > #insert control.errorest > errorest(Surv(time, cens) ~ ., data=learn, model=bagging, + est.para=control.errorest(k=2, random=FALSE), nbagg=5) Error in a$specials[[i]] : subscript out of bounds Calls: errorest ... EventHistory.frame -> model.design -> delete.response -> off Execution halted Flavor: r-devel-linux-x86_64-debian-gcc