From c8a661a40e7638f3117501ebb167df6b7337707c Mon Sep 17 00:00:00 2001 From: Liang Zhang Date: Sun, 6 Oct 2024 14:40:01 +0800 Subject: [PATCH 1/5] Add issue links in NEWS --- NEWS.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/NEWS.md b/NEWS.md index a1ecabd..0b91d92 100644 --- a/NEWS.md +++ b/NEWS.md @@ -2,8 +2,8 @@ ## New features -* Added `summary()` method to summarize the results of the CPM analysis. -* Added `tidy()` method to tidy the results of the CPM analysis. +* Added `summary()` method to summarize the results of the CPM analysis (#8). +* Added `tidy()` method to tidy the results of the CPM analysis (#10). * Support `na_action` argument in `cpm()` function to handle missing values in the input data (#2). ## Enhancements From 6267a62a6deec4ae1d6a41b1d0628559ed51bd88 Mon Sep 17 00:00:00 2001 From: Liang Zhang Date: Sun, 6 Oct 2024 14:48:03 +0800 Subject: [PATCH 2/5] Fix check notes --- R/cpm.R | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/R/cpm.R b/R/cpm.R index f8142b8..f84fb4f 100644 --- a/R/cpm.R +++ b/R/cpm.R @@ -133,10 +133,10 @@ cpm <- function(conmat, behav, ..., exclude = Reduce( function(x, y) intersect(x, y), list( - which(complete.cases(conmat)), - which(complete.cases(behav)), + which(stats::complete.cases(conmat)), + which(stats::complete.cases(behav)), if (!is.null(confounds)) { - which(complete.cases(confounds)) + which(stats::complete.cases(confounds)) } else { seq_along(behav) } @@ -225,7 +225,7 @@ print.cpm <- function(x, ...) { cat(" Call: ") print(x$call) cat(sprintf(" Number of observations: %d\n", length(x$real))) - cat(sprintf(" Complete cases: %d\n", sum(complete.cases(x$pred)))) + cat(sprintf(" Complete cases: %d\n", sum(stats::complete.cases(x$pred)))) if (!is.null(x$edges)) { cat(sprintf(" Number of edges: %d\n", dim(x$edges)[1])) } else { From 315788a02e2b3754382b7db69f186c51dbed714f Mon Sep 17 00:00:00 2001 From: Liang Zhang Date: Sun, 6 Oct 2024 14:53:31 +0800 Subject: [PATCH 3/5] Update link anchor --- R/tidy.R | 2 +- man/tidy.cpm.Rd | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/R/tidy.R b/R/tidy.R index dfccb24..29f447b 100644 --- a/R/tidy.R +++ b/R/tidy.R @@ -7,7 +7,7 @@ generics::tidy #' @param x A `cpm` object. #' @param ... Additional arguments passed to `summary()`. #' @param component A character vector indicating the component to tidy. -#' @return A [tibble][tibble-package] with columns storing parameters of the +#' @return A [tibble][tibble::tibble-package] with columns storing parameters of the #' [cpm()] object and further columns depending on the `component` argument: #' #' For `component = "performance"`: diff --git a/man/tidy.cpm.Rd b/man/tidy.cpm.Rd index 4cfdff0..eb4e0c8 100644 --- a/man/tidy.cpm.Rd +++ b/man/tidy.cpm.Rd @@ -14,7 +14,7 @@ \item{component}{A character vector indicating the component to tidy.} } \value{ -A \link[=tibble-package]{tibble} with columns storing parameters of the +A \link[tibble:tibble-package]{tibble} with columns storing parameters of the \code{\link[=cpm]{cpm()}} object and further columns depending on the \code{component} argument: For \code{component = "performance"}: From 392c4e9ce92aa7839e28f681d658712afda45ace Mon Sep 17 00:00:00 2001 From: Liang Zhang Date: Sun, 6 Oct 2024 14:58:09 +0800 Subject: [PATCH 4/5] Update cran comments --- cran-comments.md | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/cran-comments.md b/cran-comments.md index d6a0fba..b21fce6 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,15 +1,3 @@ ## R CMD check results -0 errors | 0 warnings | 1 note - -* This is a new release. - -The NOTE is as follows: - -``` -❯ checking for non-standard things in the check directory ... NOTE - Found the following files/directories: - ''NULL'' -``` - -As noted in [this issue](https://github.com/r-hub/rhub/issues/560), this is a known issue with the `rhub` package and can be safely ignored. +Use `devtools::check_win_devel()` shows no errors, warnings and notes. From 9853375200efe8dfc100c10bdcf1ae4046ab3314 Mon Sep 17 00:00:00 2001 From: Liang Zhang Date: Sun, 6 Oct 2024 15:00:43 +0800 Subject: [PATCH 5/5] Increment version number to 0.1.0 --- DESCRIPTION | 2 +- NEWS.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 2a96c41..9465145 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: cpmr Title: Connectome Predictive Modelling in R -Version: 0.0.9.9000 +Version: 0.1.0 Authors@R: person("Liang", "Zhang", , "psychelzh@outlook.com", role = c("aut", "cre"), comment = c(ORCID = "0000-0001-9041-1150")) diff --git a/NEWS.md b/NEWS.md index 0b91d92..4c84c38 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,4 +1,4 @@ -# cpmr (development version) +# cpmr 0.1.0 ## New features