From 95861bc7a337509e13e98ca5a140916a7281c6ae Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Sun, 18 Jan 2026 09:16:23 +0100 Subject: [PATCH 01/11] update documentation for imported function Surv() based on upgrade suvival package --- man/Surv.Rd | 24 +++++++++++++++--------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/man/Surv.Rd b/man/Surv.Rd index 655ffd45..8f831c84 100644 --- a/man/Surv.Rd +++ b/man/Surv.Rd @@ -5,7 +5,7 @@ \title{Create a Survival Object} \usage{ Surv(time, time2, event, type = c("right", "left", "interval", "counting", - "interval2", "mstate"), origin = 0) + "interval2"), origin = 0) } \arguments{ \item{time}{ @@ -17,17 +17,20 @@ Surv(time, time2, event, type = c("right", "left", "interval", "counting", ending time of the interval for interval censored or counting process data only. Intervals are assumed to be open on the left and closed on the right, \code{(start, end]}. For counting process - data, \code{event} indicates whether an event occurred at the end of - the interval. + data, \code{event} indicates whether a transtion to another state + occurred at the end of the interval. } \item{event}{ The status indicator, normally 0=alive, 1=dead. Other choices are - \code{TRUE}/\code{FALSE} (\code{TRUE} = death) or 1/2 (2=death). For - interval censored data, the status indicator is 0=right censored, + \code{TRUE}/\code{FALSE} (\code{TRUE} = death), 1/2 (2=death), or + a factor variable. + For interval censored data, the status indicator is 0=right censoed, 1=event at \code{time}, 2=left censored, 3=interval censored. - For multiple endpoint data the event variable will be a factor, - whose first level is treated as censoring. + For multiple endpoint data the event variable will always be a factor, + whose first level is treated as censoring, or more formally + "no transtition at this time point". + There is no constraint on the labels of the factor. Although unusual, the event indicator can be omitted, in which case all subjects are assumed to have an event. } @@ -35,7 +38,9 @@ Surv(time, time2, event, type = c("right", "left", "interval", "counting", \item{type}{ character string specifying the type of censoring. Possible values are \code{"right"}, \code{"left"}, \code{"counting"}, - \code{"interval"}, \code{"interval2"} or \code{"mstate"}. + \code{"interval"}, \code{"interval2"}. The default is multi-state + if \code{event} is a factor, counting process if \code{time2} is + present, or right censored, in that order. } \item{origin}{ @@ -43,7 +48,8 @@ Surv(time, time2, event, type = c("right", "left", "interval", "counting", was intended to be used in conjunction with a model containing time dependent strata in order to align the subjects properly when they cross over - from one strata to another, but it has rarely proven useful.} + from one strata to another, but it has rarely proven useful and is + depricated.} } \description{ This function just calls \code{Surv()} from the From a0e56ecdb8480803ffcfac4cc73b55722bd86136 Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Sun, 18 Jan 2026 09:17:46 +0100 Subject: [PATCH 02/11] Increment version number to 1.1.0 --- DESCRIPTION | 2 +- NEWS.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index badcc98f..de3a3462 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,5 +1,5 @@ Package: JointAI -Version: 1.0.6.9000 +Version: 1.1.0 Title: Joint Analysis and Imputation of Incomplete Data Authors@R: c(person("Nicole S.", "Erler", email = "n.s.erler@umcutrecht.nl", role = c("aut", "cre"), diff --git a/NEWS.md b/NEWS.md index 007197e2..bbdb966f 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,4 +1,4 @@ -# JointAI (development version) +# JointAI 1.1.0 ## New features * Added functions `crosscorr()`, `crosscorr_plot()`, `autocorr()` and `autocorr_plot()` From b78e732f75733076dbc93f20386342299e17db21 Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Sun, 18 Jan 2026 09:56:48 +0100 Subject: [PATCH 03/11] fixed typo --- R/helpfunctions_checks.R | 2 +- man/check_fixed_random.Rd | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/R/helpfunctions_checks.R b/R/helpfunctions_checks.R index 490ef822..e58c09f2 100644 --- a/R/helpfunctions_checks.R +++ b/R/helpfunctions_checks.R @@ -150,7 +150,7 @@ resolve_family_obj <- function(family) { return(thefamily) } -#' Check wheather fixed or formula contains a random effects specification +#' Check whether fixed or formula contains a random effects specification #' #' Checks if the objects provided to the `formula` and `fixed` arguments contain #' a random effects specification. This function is used in random effects diff --git a/man/check_fixed_random.Rd b/man/check_fixed_random.Rd index f82054de..a5d3f261 100644 --- a/man/check_fixed_random.Rd +++ b/man/check_fixed_random.Rd @@ -2,7 +2,7 @@ % Please edit documentation in R/helpfunctions_checks.R \name{check_fixed_random} \alias{check_fixed_random} -\title{Check wheather fixed or formula contains a random effects specification} +\title{Check whether fixed or formula contains a random effects specification} \usage{ check_fixed_random(arglist) } From 47a493db7083198ea4e1c183b4beccdb840d0f75 Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Sun, 18 Jan 2026 09:57:50 +0100 Subject: [PATCH 04/11] update r cmd check action with new version of checkout and removing unnecessary (?) lines --- .github/workflows/R-CMD-check.yaml | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index 236a8acd..3aeca8c5 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -2,7 +2,6 @@ on: push: branches: [main, master] pull_request: - branches: [main, master] name: R-CMD-check @@ -31,7 +30,7 @@ jobs: steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - uses: r-lib/actions/setup-pandoc@v2 @@ -56,7 +55,7 @@ jobs: key: ${{ runner.os }}-jags-4.3.1 restore-keys: | ${{ runner.os }}-jags- - + # Install JAGS on Windows - name: Install JAGS (Windows) if: runner.os == 'Windows' @@ -71,14 +70,6 @@ jobs: echo "JAGS found in cache, skipping installation" ) - - name: Install system dependencies - if: runner.os == 'Linux' - run: | - while read -r cmd - do - eval sudo $cmd - done < <(Rscript -e 'cat(remotes::system_requirements("ubuntu", "20.04"), sep = "\n")') - - uses: r-lib/actions/setup-r-dependencies@v2 with: From 04be471291eea42ddad4043b0301a52ef867282a Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Sun, 18 Jan 2026 09:58:13 +0100 Subject: [PATCH 05/11] set-up cran comments for submission of version 1.1.0 --- cran-comments.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/cran-comments.md b/cran-comments.md index 134bc749..2fe2d7e9 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,3 +1,28 @@ +# JointAI (version 1.1.0) + +## Round 1 + +### Test environments +* local macOS Darwin 25.2.0, R 4.5.2 +* windows server 2022 x64 (via github actions), R 4.5.2 +* ubuntu 24.04.3 LTS (via github actions), R 4.4.3, R 4.5.2, devel +* macOS Sequoia 15.7.2 (via github actions), R 4.5.2 +* win-builder (oldrelease, devel and release) + + +### R CMD check results +0 errors | 0 warnings | 0 notes on current & devel + +R-oldrelease shows one codoc mismatch for `survival::Surv()` due +to outdated documentation in that R version. Current and devel are clean. + + +### Reverse dependencies +One reverse dependency: "remiod"; passed the check. + +--- + + # JointAI (version 1.0.6) ## Round 1 From e923d39013c87814f7e131dd730c8e9e80f4681f Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Sat, 24 Jan 2026 10:29:03 +0100 Subject: [PATCH 06/11] Bugfix causing failure in rd_vcov() for multivariate mixed models, since the list to be melted contains matrices, not vectors. Issue likely introduced in 1e163fa, by restricting to atomic vectors. --- R/helpfunctions_melt.R | 49 +++++++++++++++++++++++++----------------- 1 file changed, 29 insertions(+), 20 deletions(-) diff --git a/R/helpfunctions_melt.R b/R/helpfunctions_melt.R index 793f0d95..ac0a9ad9 100644 --- a/R/helpfunctions_melt.R +++ b/R/helpfunctions_melt.R @@ -30,29 +30,38 @@ melt_list <- function(l, varname = "L1", valname = "value") { # Check for elements that cannot be converted to a data.frame or would # result in differing numbers of columns e.g., formulas, arrays, lists, ... - if (any(lvapply(l, function(x) !is.atomic(x) | !is.vector(x)))) { + if (all(lvapply(l, function(x) is.atomic(x) & is.vector(x)))) { + do.call( + rbind, + lapply(seq_along(l), function(k) { + df <- as.data.frame( + list(l[[k]]), + col.names = valname, + stringsAsFactors = FALSE + ) + + df[, varname] <- names(l)[k] + df + }) + ) + } else if (all(lvapply(l, function(x) is.atomic(x) & inherits(x, "matrix")))) { + do.call( + rbind, + lapply(seq_along(l), function(k) { + df <- as.data.frame( + list(l[[k]]), + stringsAsFactors = FALSE + ) + df[, varname] <- names(l)[k] + df + }) + ) + } else { errormsg( - "In melt_list(): Not all elements are atomic vectors (%s).", - paste_and( - names(Filter(function(x) !is.atomic(x) | !is.vector(x), l)), - dQ = TRUE - ) + "In melt_list(): Not all elements are atomic vectors or matrices (%s). + I don't know how to convert this." ) } - - do.call( - rbind, - lapply(seq_along(l), function(k) { - df <- as.data.frame( - list(l[[k]]), - col.names = valname, - stringsAsFactors = FALSE - ) - - df[, varname] <- names(l)[k] - df - }) - ) } From 1234b96a3f0e03ccc0f9644435ee38a7e62585c2 Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Sat, 24 Jan 2026 10:30:53 +0100 Subject: [PATCH 07/11] enable running R CMD Check workflow "by hand" --- .github/workflows/R-CMD-check.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index 3aeca8c5..062d7f47 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -2,6 +2,7 @@ on: push: branches: [main, master] pull_request: + workflow_dispatch: name: R-CMD-check From dc3a88e812aea242378ea2be731a5a35510484ba Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Thu, 29 Jan 2026 17:46:36 +0100 Subject: [PATCH 08/11] add bugfix in rd_vcov to NEWS.md --- NEWS.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/NEWS.md b/NEWS.md index bbdb966f..a9508c6f 100644 --- a/NEWS.md +++ b/NEWS.md @@ -20,6 +20,9 @@ * Fix in identifying the number of workers used in parallel computation with the **future** package. * Fix `summary()` printout showing the wrong MCMC settings when using thinning. +* `rd_vcov()`: fixed issue resulting in error when extracting random effects + variance-covariance matrix from fitted model in case of a multivariate mixed + model. -------------------------------------------------------------------------------- From 46b2810f8c81fdd9e2ace148e6b4e661553b08c8 Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Fri, 30 Jan 2026 07:42:37 +0100 Subject: [PATCH 09/11] explicitly install survival package before R CMD check to get the latest version --- .github/workflows/R-CMD-check.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index 062d7f47..f4cc13f9 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -74,7 +74,7 @@ jobs: - uses: r-lib/actions/setup-r-dependencies@v2 with: - extra-packages: any::rcmdcheck + extra-packages: any::rcmdcheck, any::survival needs: check From f89308b62439896a8713fc3e264ce09e0d21d569 Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Fri, 30 Jan 2026 08:00:13 +0100 Subject: [PATCH 10/11] bump cache version to force reinstallation of dependencies (especially the survival package) --- .github/workflows/R-CMD-check.yaml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index f4cc13f9..aa41f615 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -74,7 +74,11 @@ jobs: - uses: r-lib/actions/setup-r-dependencies@v2 with: - extra-packages: any::rcmdcheck, any::survival + extra-packages: | + any::survival + any::rcmdcheck + upgrade: 'TRUE' + cache-version: 2 needs: check From eabb9d16da8a4da0d30b6aa09716a0788f3d74d1 Mon Sep 17 00:00:00 2001 From: Nicole Erler Date: Fri, 30 Jan 2026 08:27:35 +0100 Subject: [PATCH 11/11] Update cran-comments with win-builder results --- cran-comments.md | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/cran-comments.md b/cran-comments.md index 2fe2d7e9..b327d086 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -11,10 +11,14 @@ ### R CMD check results -0 errors | 0 warnings | 0 notes on current & devel - -R-oldrelease shows one codoc mismatch for `survival::Surv()` due -to outdated documentation in that R version. Current and devel are clean. +0 errors | 0 warnings | 1-2 NOTES on win-builder + +#### NOTES +* The Maintainer e-mail address has changed from `n.erler@erasmusmc.nl` to + `n.s.erler@umcutrecht.nl`. This is intentional. +* oldrel-only: “Author field differs from that derived from Authors@R” + This NOTE appears only on R-oldrelease, likely due to differences in how older + R formats ORCID information. ### Reverse dependencies