Running ‘Colr-pen.R’ [49s/95s]
Running the tests in ‘tests/Colr-pen.R’ failed.
Complete output:
  > # Tests for COLR models
  > 
  > ## Depencies
  > ## IGNORE_RDIFF_BEGIN
  > library("tramnet")
  Loading required package: tram
  Loading required package: mlt
  Loading required package: basefun
  Loading required package: variables
  Loading required package: CVXR
  
  Attaching package: 'CVXR'
  
  The following object is masked from 'package:stats':
  
      power
  
  Loading required package: mlrMBO
  Loading required package: mlr
  Loading required package: ParamHelpers
  Warning message: 'mlr' is in 'maintenance-only' mode since July 2019.
  Future development will only happen in 'mlr3'
  (<https://mlr3.mlr-org.com>). Due to the focus on 'mlr3' there might be
  uncaught bugs meanwhile in {mlr} - please consider switching.
  Loading required package: smoof
  Loading required package: checkmate
  > library("survival")
  > library("sandwich")
  > ## IGNORE_RDIFF_END
  > old <- options(digits = 3)
  > 
  > ## Exact and Right censored
  > data("GBSG2", package = "TH.data")
  > GBSG2$surv <- with(GBSG2, Surv(time, cens))
  > x <- matrix(1 * (GBSG2$horTh == "yes"), ncol = 1)
  > colnames(x) <- "horTh"
  > 
  > yCOLR <- Colr(surv ~ 1, data = GBSG2, log_first = TRUE, order = 10)
  > modCOLR <- tramnet(yCOLR, x, lambda = 0, alpha = 0)
  > yCOLRb <- Colr(surv ~ horTh, data = GBSG2, log_first = TRUE, order = 10)
  > max(abs(coef(yCOLRb, with_baseline = FALSE) -
  +         coef(modCOLR, with_baseline = FALSE)))
  [1] 1.51e-05
  > logLik(yCOLRb)
  'log Lik.' -2606 (df=12)
  > logLik(modCOLR)
  'log Lik.' -2606 (df=NA)
  > -modCOLR$result$value
  [1] -2606
  > logLik(modCOLR, newdata = tramnet:::.get_tramnet_data(modCOLR)[1:10, ])
  'log Lik.' -59 (df=NA)
  > 
  > ## methods
  > coef(modCOLR, tol = 0, with_baseline = TRUE)
   Bs1(surv)  Bs2(surv)  Bs3(surv)  Bs4(surv)  Bs5(surv)  Bs6(surv)  Bs7(surv) 
     -2.1005    -1.6468    -1.4018    -0.6926    -0.6926    -0.6926    -0.2411 
   Bs8(surv)  Bs9(surv) Bs10(surv) Bs11(surv)      horTh 
     -0.0263    -0.0263     0.2935     0.7648    -0.4796 
  > logLik(modCOLR)
  'log Lik.' -2606 (df=NA)
  > c(resid(modCOLR)[1:10])
        1       2       3       4       5       6       7       8       9      10 
   0.0931 -0.0658 -0.6044 -0.1480 -0.3839 -0.7158  0.5009  0.6161 -0.6885  0.5853 
  > predict(modCOLR, type = "distribution", q = 1)[, 1:10]
   [1] 4.74e-08 2.93e-08 2.93e-08 2.93e-08 4.74e-08 4.74e-08 2.93e-08 4.74e-08
   [9] 4.74e-08 4.74e-08
  > predict(modCOLR, type = "quantile", prob = 0.5)[, 1:10]
   [1] 1560 2168 2168 2168 1560 1560 2168 1560 1560 1560
  > head(simulate(modCOLR))
  Error in R.numeric(as.vector(nexact), cleft = as.vector(nleft), cright = as.vector(nright)) : 
    cleft > cright
  Calls: head ... simulate -> simulate.ctm -> .invf -> R -> R.numeric
  Execution halted