Running 'testthat.R' [1s/1s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > library(testthat)
  > library(IGP)
  
  Initialize Python Version 2.7.16 (default, Mar  4 2019, 15:29:09) 
  [GCC 8.3.0]
  
  > 
  > test_check("IGP")
  [1] "laGP"
  [1] "mlegp"
  -- 1. Error: 1D data works (@test_IGP.R#11)  -----------------------------------
  BLAS/LAPACK routine 'DPPTRS' gave error code -1
  1: IGP(package = package, X = X1, Z = Z1) at testthat/test_IGP.R:11
  2: IGP_mlegp$new(X = X, Z = Z, ...)
  3: .subset2(public_bind_env, "initialize")(...)
  4: self$init(...)
  5: self$.init(...)
  6: capture.output(m <- do.call(mlegp::mlegp, argss))
  7: evalVis(expr)
  8: withVisible(eval(expr, pf))
  9: eval(expr, pf)
  10: eval(expr, pf)
  11: do.call(mlegp::mlegp, argss)
  12: (function (X, Z, constantMean = 1, nugget = NULL, nugget.known = 0, min.nugget = 0, 
         param.names = NULL, gp.names = NULL, PC.UD = NULL, PC.num = NULL, PC.percent = NULL, 
         simplex.ntries = 5, simplex.maxiter = 500, simplex.reltol = 1e-08, BFGS.maxiter = 500, 
         BFGS.tol = 0.01, BFGS.h = 1e-10, seed = 0, verbose = 1, parallel = FALSE) 
     {
         X = as.matrix(X)
         orig.X = X
         Z = as.matrix(Z)
         reps = NULL
         un.sum = NULL
         if (nrow(X) == 1) {
             stop("error: there must be at least two input values")
         }
         if (!is.null(param.names) && length(param.names) != dim(X)[2]) {
             stop("length of param.names must match number of columns of X")
         }
         if (!is.null(PC.percent)) 
             PC.num = numSingularValues(Z, PC.percent)
         if (!is.null(PC.num)) {
             weights = pcweights(Z, weights.num = PC.num)
             Z = t(weights$Vprime)
             if (PC.num == 1) {
                 stop("error: currently not implemented for PC.num = 1 (set PC.num directly)")
             }
             PC.UD = weights$UD
         }
         if (!is.null(dim(Z))) {
             numGPs = dim(Z)[2]
         }
         else {
             numGPs = 1
             Z = matrix(Z)
         }
         if (length(seed) != 1 && length(seed) != ncol(Z)) {
             stop("error: seed length must equal dimensions of Z, or 1")
         }
         if (is.null(gp.names)) {
             gp.names = paste("gp #", 1:numGPs)
         }
         if (length(gp.names) != numGPs) {
             stop("length of gp.names must match number of GPs")
         }
         if (dim(X)[1] != dim(Z)[1]) {
             stop("error: X matrix and output matrix must have same number of rows; \n\tfor PC weights, make sure each column of Z is a computer model run")
         }
         if (min(diag(var(Z))) <= 0) {
             stop("error: Z does not vary for at least one column")
         }
         if (dim(Z)[2] > 1 && !is.null(nugget) && length(nugget) > 1) {
             stop("error: cannot handle nugget matrix with multiple field observations; try fitting 1 gp at a time")
         }
         if (!is.null(nugget) && length(nugget) > dim(Z)[1]) {
             stop("length of nugget matrix must match number of observations")
         }
         if (min(apply(X, 2, max) - apply(X, 2, min)) == 0) {
             stop("error: at least one parameter does not vary in design")
         }
         if (constantMean != 1) {
             ones = rep(1, dim(X)[1])
             dX = cbind(ones, X)
             t = try(solve(t(dX) %*% dX), TRUE)
             if (class(t) == "try-error") {
                 stop("error: design matrix with intercept is not full rank; set constantMean = 1")
             }
         }
         if (nugget.known == 1) {
             if (!is.null(nugget) && length(nugget) > 1 && length(nugget) != nrow(X)) {
                 stop("error: for nugget.known = 1, length of nugget matrix must be nrow(X) or 1")
             }
             un.sum = uniqueSummary(X, Z)
             orig.X = X
             X = un.sum$uniqueX
             Z = un.sum$uniqueMeans
             reps = un.sum$reps
         }
         if (!is.null(nugget) && length(nugget) == 1 && nugget <= 0) {
             if (anyReps(X)) 
                 stop("at least 2 or more inputs are identical...must use nugget!")
         }
         if (is.null(nugget)) {
             if (!anyReps(X)) {
                 if (verbose > 0) 
                     cat("no reps detected - nugget will not be estimated\n")
             }
             else {
                 if (verbose > 0 && nugget.known == 0) 
                     cat("reps detected - nugget will be estimated\n")
             }
         }
         numEstimates = dim(X)[2] + 1
         if (anyReps(X) || !is.null(nugget) || length(nugget) > 1) 
             numEstimates = numEstimates + 1
         if (constantMean == 1) {
             numEstimates = numEstimates + 1
         }
         else {
             numEstimates = numEstimates + dim(X)[2] + 1
         }
         estimates = rep(0, numEstimates)
         if (verbose > 0) 
             cat("\n")
         l = NULL
         Zlist = list()
         if (length(seed) == 1) 
             seed = rep(seed, ncol(Z))
         for (i in 1:ncol(Z)) {
             Zlist[[i]] = list()
             Zlist[[i]]$Z = matrix(Z[, i])
             Zlist[[i]]$i = i
             Zlist[[i]]$seed = seed[i]
         }
         if (!parallel) {
             l = lapply(Zlist, mlegp2, XX = X, orig.XX = orig.X, nugget = nugget, nugget.known = nugget.known, 
                 reps = reps, un.sum = un.sum, numEstimates = numEstimates, constantMean = constantMean, 
                 simplex.ntries = simplex.ntries, simplex.maxiter = simplex.maxiter, simplex.reltol = simplex.reltol, 
                 BFGS.maxiter = BFGS.maxiter, BFGS.tol = BFGS.tol, BFGS.h = BFGS.h, min.nugget = min.nugget, 
                 verbose = verbose, param.names = param.names)
         }
         if (parallel) {
             if (requireNamespace("snowfall", quietly = TRUE)) {
                 cat("fitting ")
                 cat(length(Zlist))
                 cat(" GPs in parallel mode...\n")
                 l = snowfall::sfLapply(Zlist, mlegp2, XX = X, orig.XX = orig.X, nugget = nugget, 
                     nugget.known = nugget.known, reps = reps, un.sum = un.sum, numEstimates = numEstimates, 
                     constantMean = constantMean, simplex.ntries = simplex.ntries, simplex.maxiter = simplex.maxiter, 
                     simplex.reltol = simplex.reltol, BFGS.maxiter = BFGS.maxiter, BFGS.tol = BFGS.tol, 
                     BFGS.h = BFGS.h, min.nugget = min.nugget, verbose = verbose, param.names = param.names)
                 cat("...done\n")
             }
             else {
                 cat("Error: the package \"snowfall\" is required when parallel = TRUE")
             }
         }
         if (numGPs == 1) {
             return(l[[1]])
         }
         return(gp.list(l, UD = PC.UD, param.names = param.names, gp.names = gp.names))
     })(X = structure(c(0.386332090944052, 0.878003114135936, 0.522932142717764, 0.867485535796732, 
     0.665318534243852, 0.737201165640727, 0.57599563873373, 0.7524371559266, 0.703815854387358, 
     0.215415321988985, 0.152231378946453, 0.480125757399946, 0.63067302852869, 0.187127737561241, 
     0.897559011355042, 0.484741016291082, 0.697923224885017, 0.194339874666184, 0.133605078794062, 
     0.73667134041898, 0.951278996421024, 0.447041123174131, 0.693911544512957, 0.589282332221046, 
     0.0284350209403783, 0.185143474955112, 0.384441740112379, 0.264006807468832, 0.249923732830212, 
     0.448537911521271, 0.630876391660422, 0.698677025502548, 0.667772404383868, 0.0535267249215394, 
     0.186910271411762, 0.468251856975257, 0.782261919463053, 0.36853904183954, 0.224161167629063, 
     0.339970664819703, 0.757940022740513, 0.847228867700323, 0.118270868668333, 0.0585093612316996, 
     0.0819270759820938, 0.213136851554736, 0.317822622833773, 0.961124764755368, 0.792916882084683, 
     0.264016970992088, 0.803529739147052, 0.459709001937881, 0.397152327233925, 0.792520878138021, 
     0.867498841136694, 0.475962412310764, 0.633061060449108, 0.234439476858824, 0.555562069173902, 
     0.760448741959408, 0.128627387806773, 0.817545427009463, 0.919908973155543, 0.991485998267308, 
     0.854960772208869, 0.315687793307006, 0.527294008526951, 0.151803631102666, 0.362064891960472, 
     0.492775988066569, 0.603515678551048, 0.494936664123088, 0.89286591950804, 0.050499175908044, 
     0.948850003071129, 0.0200058342888951, 0.419594340724871, 0.0824895510450006, 0.740704153198749, 
     0.969130333280191), .Dim = c(40L, 2L)), Z = c(-0.343562108610091, -1.51336402481357, 
     0.531422358701615, -0.380901299306804, -0.37022777314931, -0.0236119530468903, 0.450621647666486, 
     -1.24078538349501, -1.92111390307493, 1.97321950045241, -0.126730386104096, 0.373707389829196, 
     -0.129452343969781, -0.0421503283239983, -1.34021730778112, 0.248065186708509, -1.68962009927362, 
     1.93375454786982, 0.403580754027017, -1.99426448229883, 0.423616363493904, -0.58605875857008, 
     -1.42062805896142, -0.584845727073279, -0.612003308176021, 1.83492056975163, 0.494341677568525, 
     1.8125079943914, 1.76367624012199, 0.363437304483971, -1.33640881555353, -0.91601709902064, 
     -1.49378562647115, 0.64143718507699, 0.606758219326375, 0.324815586013823, -0.495538170135473, 
     1.23187676776388, -0.0121546748274733, 0.653385702020546), verbose = 0, nugget = 1e-08, 
         nugget.known = 1e-08)
  13: lapply(Zlist, mlegp2, XX = X, orig.XX = orig.X, nugget = nugget, nugget.known = nugget.known, 
         reps = reps, un.sum = un.sum, numEstimates = numEstimates, constantMean = constantMean, 
         simplex.ntries = simplex.ntries, simplex.maxiter = simplex.maxiter, simplex.reltol = simplex.reltol, 
         BFGS.maxiter = BFGS.maxiter, BFGS.tol = BFGS.tol, BFGS.h = BFGS.h, min.nugget = min.nugget, 
         verbose = verbose, param.names = param.names)
  14: FUN(X[[i]], ...)
  
  == testthat results  ===========================================================
  OK: 11 SKIPPED: 0 FAILED: 1
  1. Error: 1D data works (@test_IGP.R#11) 
  
  Error: testthat unit tests failed
  Execution halted