* using log directory ‘/data/gannet/ripley/R/packages/tests-LENGTH1/dbstats.Rcheck’ * using R Under development (unstable) (2022-04-26 r82260) * using platform: x86_64-pc-linux-gnu (64-bit) * using session charset: UTF-8 * using option ‘--no-stop-on-test-error’ * checking for file ‘dbstats/DESCRIPTION’ ... OK * checking extension type ... Package * this is package ‘dbstats’ version ‘1.0.5’ * checking package namespace information ... OK * checking package dependencies ... OK * checking if this is a source package ... OK * checking if there is a namespace ... OK * checking for executable files ... OK * checking for hidden files and directories ... OK * checking for portable file names ... OK * checking for sufficient/correct file permissions ... OK * checking whether package ‘dbstats’ can be installed ... [10s/26s] OK * checking package directory ... OK * checking DESCRIPTION meta-information ... OK * checking top-level files ... OK * checking for left-over files ... OK * checking index information ... OK * checking package subdirectories ... OK * checking R files for non-ASCII characters ... OK * checking R files for syntax errors ... OK * checking whether the package can be loaded ... OK * checking whether the package can be loaded with stated dependencies ... OK * checking whether the package can be unloaded cleanly ... OK * checking whether the namespace can be loaded with stated dependencies ... OK * checking whether the namespace can be unloaded cleanly ... OK * checking loading without being on the library search path ... OK * checking use of S3 registration ... OK * checking dependencies in R code ... OK * checking S3 generic/method consistency ... OK * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... [23s/60s] OK * checking Rd files ... OK * checking Rd metadata ... OK * checking Rd line widths ... OK * checking Rd cross-references ... OK * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... OK * checking Rd contents ... OK * checking for unstated dependencies in examples ... OK * checking examples ... ERROR Running examples in ‘dbstats-Ex.R’ failed The error most likely occurred in: > ### Name: dbplsr > ### Title: Distance-based partial least squares regression > ### Aliases: dbplsr dbplsr.formula dbplsr.dist dbplsr.D2 dbplsr.Gram > ### print.dbplsr > > ### ** Examples > > #require(pls) > library(pls) > data(yarn) > ## Default methods: > yarn.dbplsr <- dbplsr(density ~ NIR, data = yarn, ncomp=6, method="GCV") ----------- FAILURE REPORT -------------- --- failure: length > 1 in coercion to logical --- --- srcref --- : --- package (from environment) --- dbstats --- call from context --- z_to_dist(z, metric) --- call from argument --- class(z) != "data.frame" && class(z) != "matrix" --- R stacktrace --- where 1: z_to_dist(z, metric) where 2: dbplsr.yz(z = zy$z, y = zy$y, metric = metric, weights = weights, method = method, ncomp = ncomp) where 3: doTryCatch(return(expr), name, parentenv, handler) where 4: tryCatchOne(expr, names, parentenv, handlers[[1L]]) where 5: tryCatchList(expr, classes, parentenv, handlers) where 6: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)) { if (identical(call[[1L]], quote(doTryCatch))) call <- sys.call(-4L) dcall <- deparse(call, nlines = 1L) prefix <- paste("Error in", dcall, ": ") LONG <- 75L sm <- strsplit(conditionMessage(e), "\n")[[1L]] w <- 14L + nchar(dcall, type = "w") + nchar(sm[1L], type = "w") if (is.na(w)) w <- 14L + nchar(dcall, type = "b") + nchar(sm[1L], type = "b") if (w > LONG) prefix <- paste0(prefix, "\n ") } else prefix <- "Error : " msg <- paste0(prefix, conditionMessage(e), "\n") .Internal(seterrmessage(msg[1L])) if (!silent && isTRUE(getOption("show.error.messages"))) { cat(msg, file = outFile) .Internal(printDeferredWarnings()) } invisible(structure(msg, class = "try-error", condition = e)) }) where 7: try(ans <- dbplsr.yz(z = zy$z, y = zy$y, metric = metric, weights = weights, method = method, ncomp = ncomp)) where 8: dbplsr.formula(density ~ NIR, data = yarn, ncomp = 6, method = "GCV") where 9: dbplsr(density ~ NIR, data = yarn, ncomp = 6, method = "GCV") --- value of length: 2 type: logical --- [1] TRUE TRUE --- function from context --- function (z, metric) { if (class(z)[1] == "dist" || class(z)[1] == "dissimilarity" || class(z)[1] == "D2") { D <- z way <- "D2" } else { if (is.numeric(z)) z <- as.matrix(z) if (is.factor(z)) z <- data.frame(z) if (class(z) != "data.frame" && class(z) != "matrix") stop("'z' must be matrix/data.frame or a numeric vector") else { D <- daisy(z, metric = metric) way <- "Z" } } return(list(D = D, way = way)) } --- function search by body --- Function z_to_dist in namespace dbstats has this body. ----------- END OF FAILURE REPORT -------------- Fatal error: length > 1 in coercion to logical * checking PDF version of manual ... OK * checking for non-standard things in the check directory ... OK * checking for detritus in the temp directory ... OK * DONE Status: 1 ERROR See ‘/data/gannet/ripley/R/packages/tests-LENGTH1/dbstats.Rcheck/00check.log’ for details. Command exited with non-zero status 1 Time 3:07.18, 64.43 + 6.32