The hardware and bandwidth for this mirror is donated by METANET, the Webhosting and Full Service-Cloud Provider.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]metanet.ch.

CRAN Package Check Results for Package hesim

Last updated on 2026-10-24 05:51:17 CEST.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-clang 0.5.8 233.06 392.09 625.15 OK
r-devel-linux-x86_64-debian-gcc 0.5.8 186.87 271.08 457.95 ERROR
r-devel-linux-x86_64-fedora-clang 0.5.8 163.00 300.65 463.65 OK
r-devel-linux-x86_64-fedora-gcc 0.5.8 211.00 268.48 479.48 OK
r-devel-windows-x86_64 0.5.8 283.00 525.00 808.00 OK
r-patched-linux-x86_64 0.5.8 256.92 363.44 620.36 OK
r-release-linux-x86_64 0.5.8 254.17 366.33 620.50 OK
r-release-macos-arm64 0.5.8 47.00 57.00 104.00 OK
r-release-macos-x86_64 0.5.8 154.00 409.00 563.00 OK
r-release-windows-x86_64 0.5.8 272.00 453.00 725.00 OK
r-oldrel-macos-arm64 0.5.8 45.00 62.00 107.00 OK
r-oldrel-macos-x86_64 0.5.8 158.00 276.00 434.00 OK
r-oldrel-windows-x86_64 0.5.8 377.00 584.00 961.00 OK

Check Details

Version: 0.5.8
Check: examples
Result: ERROR Running examples in ‘hesim-Ex.R’ failed The error most likely occurred in: > base::assign(".ptime", proc.time(), pos = "CheckExEnv") > ### Name: sim_stateprobs.survival > ### Title: Simulate state probabilities from survival curves > ### Aliases: sim_stateprobs.survival > > ### ** Examples > > library("data.table") Attaching package: ‘data.table’ The following object is masked from ‘package:base’: %notin% > library("survival") > > # This example shows how to simulate a partitioned survival model by > # manually constructing a "survival" object. We will consider a case in which > # Cox proportional hazards models from the survival package---which are not > # integrated with hesim---are used for parameter estimation. We will use > # point estimates in the example, but bootstrapping, Bayesian modeling, > # or other techniques could be used to draw samples for a probabilistic > # sensitivity analysis. > > # (0) We first setup our model per usual by defining the treatment strategies, > # target population, and health states > hesim_dat <- hesim_data( + strategies = data.table(strategy_id = 1:3, + strategy_name = c("SOC", "New 1", "New 2")), + patients = data.table(patient_id = 1:2, + female = c(0, 1), + grp_id = 1), + states = data.table(state_id = 1:2, + state_name = c("Stable", "Progression")) + ) > > # (1) Next we will estimate Cox models with survival::coxph(). We illustrate > # by predicting progression free survival (PFS) and overall survival (OS) > ## Fit models > onc3_pfs_os <- as_pfs_os(onc3, patient_vars = c("patient_id", "female", + "strategy_name")) > fit_pfs <- coxph(Surv(pfs_time, pfs_status) ~ strategy_name + female, + data = onc3_pfs_os) > fit_os <- coxph(Surv(os_time, pfs_status) ~ strategy_name + female, + data = onc3_pfs_os) > > ## Predict survival on input data > surv_input_data <- expand(hesim_dat) > times <- seq(0, 14, 1/12) > predict_survival <- function(object, newdata, times) { + surv <- summary(survfit(object, newdata = newdata, se.fit = FALSE), + t = times) + pred <- newdata[rep(seq_len(nrow(newdata)), each = length(times)), ] + pred[, sample := 1] # Point estimates only in this example + pred[, time := rep(surv$time, times = nrow(newdata))] + pred[, survival := c(surv$surv)] + return(pred[, ]) + } > pfs <- predict_survival(fit_pfs, newdata = surv_input_data, times = times) Error in a$specials[[i]] : subscript out of bounds Calls: predict_survival ... survfit.coxph -> model.matrix.coxph -> delete.response -> off Execution halted Flavor: r-devel-linux-x86_64-debian-gcc

Version: 0.5.8
Check: tests
Result: ERROR Running ‘testthat.R’ [25s/29s] Running the tests in ‘tests/testthat.R’ failed. Complete output: > library(testthat) > library(hesim) > > test_check("hesim") Saving _problems/test-cpp-distributions-534.R sample = 1 sample = 2 Saving _problems/test-params_surv-226.R Saving _problems/test-params_surv_list-97.R Saving _problems/test-psm-42.R Saving _problems/test-sim-general-26.R [ FAIL 5 | WARN 3 | SKIP 0 | PASS 981 ] ══ Failed tests ════════════════════════════════════════════════════════════════ ── Error ('test-cpp-distributions.R:532:7'): survspline ──────────────────────── <subscriptOutOfBoundsError/error/condition> Error in `a$specials[[i]]`: subscript out of bounds Backtrace: ▆ 1. └─hesim (local) test_survspline2(flexsurv_scale = "hazard", timescale = "log") at test-cpp-distributions.R:610:3 2. └─flexsurv::flexsurvspline(...) at test-cpp-distributions.R:532:7 3. ├─base::do.call("flexsurvreg", args) 4. └─flexsurv::flexsurvreg(...) 5. └─dlist$inits(t = wt, mf = m, mml = mml, aux = inits.aux) 6. ├─survival::survfit(cox) 7. └─survival:::survfit.coxph(cox) 8. └─survival:::model.matrix.coxph(object, data = mf) 9. └─stats::delete.response(object$terms) 10. └─stats (local) off(a$specials[[i]]) ── Error ('test-params_surv.R:225:3'): create_params.flexsurv() ──────────────── <subscriptOutOfBoundsError/error/condition> Error in `a$specials[[i]]`: subscript out of bounds Backtrace: ▆ 1. └─flexsurv::flexsurvspline(...) at test-params_surv.R:225:3 2. ├─base::do.call("flexsurvreg", args) 3. └─flexsurv::flexsurvreg(...) 4. └─dlist$inits(t = wt, mf = m, mml = mml, aux = inits.aux) 5. ├─survival::survfit(cox, newdata = newdata) 6. └─survival:::survfit.coxph(cox, newdata = newdata) 7. └─survival:::model.matrix.coxph(object, data = mf) 8. └─stats::delete.response(object$terms) 9. └─stats (local) off(a$specials[[i]]) ── Error ('test-params_surv_list.R:96:3'): create_params.partsurvfit() works as expected ── <subscriptOutOfBoundsError/error/condition> Error in `a$specials[[i]]`: subscript out of bounds Backtrace: ▆ 1. └─flexsurv::flexsurvspline(...) at test-params_surv_list.R:96:3 2. ├─base::do.call("flexsurvreg", args) 3. └─flexsurv::flexsurvreg(...) 4. └─dlist$inits(t = wt, mf = m, mml = mml, aux = inits.aux) 5. ├─survival::survfit(cox, newdata = newdata) 6. └─survival:::survfit.coxph(cox, newdata = newdata) 7. └─survival:::model.matrix.coxph(object, data = mf) 8. └─stats::delete.response(object$terms) 9. └─stats (local) off(a$specials[[i]]) ── Error ('test-psm.R:42:3'): (code run outside of `test_that()`) ────────────── <subscriptOutOfBoundsError/error/condition> Error in `a$specials[[i]]`: subscript out of bounds Backtrace: ▆ 1. └─flexsurv::flexsurvspline(as.formula(formulas[[i]]), data = surv_est_data) at test-psm.R:42:3 2. ├─base::do.call("flexsurvreg", args) 3. └─flexsurv::flexsurvreg(...) 4. └─dlist$inits(t = wt, mf = m, mml = mml, aux = inits.aux) 5. ├─survival::survfit(cox, newdata = newdata) 6. └─survival:::survfit.coxph(cox, newdata = newdata) 7. └─survival:::model.matrix.coxph(object, data = mf) 8. └─stats::delete.response(object$terms) 9. └─stats (local) off(a$specials[[i]]) ── Error ('test-sim-general.R:25:3'): (code run outside of `test_that()`) ────── <subscriptOutOfBoundsError/error/condition> Error in `a$specials[[i]]`: subscript out of bounds Backtrace: ▆ 1. └─hesim (local) predict_survival(fit_pfs, newdata = newdat, times = times) at test-sim-general.R:33:1 2. ├─base::summary(...) at test-sim-general.R:25:3 3. ├─survival::survfit(object, newdata = newdata, se.fit = FALSE) 4. └─survival:::survfit.coxph(object, newdata = newdata, se.fit = FALSE) 5. └─survival:::model.matrix.coxph(object, data = mf) 6. └─stats::delete.response(object$terms) 7. └─stats (local) off(a$specials[[i]]) [ FAIL 5 | WARN 3 | SKIP 0 | PASS 981 ] Error: ! Test failures. Execution halted Flavor: r-devel-linux-x86_64-debian-gcc

These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.