Skip to content

Commit

Permalink
final edits before submission 2.8-1 to CRAN
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentvanhees committed Oct 1, 2022
1 parent 57ddc23 commit 65784d8
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 3 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Package: GGIR
Type: Package
Title: Raw Accelerometer Data Analysis
Version: 2.8-1
Date: 2022-09-30
Date: 2022-10-01
Authors@R: c(person("Vincent T","van Hees",role=c("aut","cre"),
email="[email protected]"),
person("Jairo H","Migueles",role="aut"),
Expand Down
9 changes: 9 additions & 0 deletions R/check_params.R
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,15 @@ check_params = function(params_sleep = c(), params_metrics = c(),
} else if (length(params_sleep[["def.noc.sleep"]]) == 2) {
params_sleep[["HASPT.algo"]] = "notused"
}
if (params_metrics[["do.neishabouricounts"]] == TRUE) {
if ("actilifecounts" %in% rownames(utils::installed.packages()) == FALSE) {
stop("\nR package actilifecounts was not found and is required for deriving the neishabouricounts", call. = FALSE)
} else {
if (utils::packageVersion("actilifecounts") < "1.1.0") {
stop("\nPlease update R package actilifecounts to version 1.1.0 or higher", call. = FALSE)
}
}
}
if (params_general[["sensor.location"]] == "hip" & params_sleep[["HASPT.algo"]] != "notused") {
if (params_metrics[["do.anglex"]] == FALSE | params_metrics[["do.angley"]] == FALSE | params_metrics[["do.anglez"]] == FALSE) {
warning(paste0("\nWhen working with hip data all three angle metrics are needed,",
Expand Down
2 changes: 1 addition & 1 deletion inst/NEWS.Rd
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
\name{NEWS}
\title{News for Package \pkg{GGIR}}
\newcommand{\cpkg}{\href{http://CRAN.R-project.org/package=#1}{\pkg{#1}}}
\section{Changes in version 2.8-1 (release date:30-09-2022)}{
\section{Changes in version 2.8-1 (release date:01-10-2022)}{
\itemize{
\item Changed POSIXlt to character conversion to be compatible with R-devel
update svn revision r82904 (2022-09-24 19:32:52)
Expand Down
2 changes: 1 addition & 1 deletion man/GGIR-package.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
Package: \tab GGIR\cr
Type: \tab Package\cr
Version: \tab 2.8-1\cr
Date: \tab 2022-09-30\cr
Date: \tab 2022-10-01\cr
License: \tab LGPL (>= 2.0, < 3)\cr
Discussion group: \tab https://groups.google.com/forum/#!forum/rpackageggir\cr
}
Expand Down
13 changes: 13 additions & 0 deletions prepareNewRelease.R
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,17 @@ prepareNewRelease = function(version = c()) {
i = i + 1
}
if (errorfound == FALSE) cat(paste0("\nNo problem found. Package consistently uses version ",version," and release date ", dateReversed))

Q1 = menu(c("Yes", "No"), title = paste0("\nDo you want to check the package with manual, remote and incoming?"))
if (Q1 == 1) {
devtools::check(
manual = TRUE,
remote = TRUE,
incoming = TRUE
)
}
Q2 = menu(c("Yes", "No"), title = paste0("\nDo you want to build the package for CRAN including manual?"))
if (Q2 == 1) {
devtools::build(manual = TRUE)
}
}

0 comments on commit 65784d8

Please sign in to comment.