Skip to content

Commit

Permalink
Merge pull request #139 from mitre/upd-cran
Browse files Browse the repository at this point in the history
Make updates for CRAN testing
  • Loading branch information
delosh653 authored Sep 19, 2023
2 parents aea2631 + 6e13895 commit cd1883f
Show file tree
Hide file tree
Showing 30 changed files with 99 additions and 26 deletions.
4 changes: 3 additions & 1 deletion R/adjustcarryforward.R
Original file line number Diff line number Diff line change
Expand Up @@ -1084,9 +1084,10 @@ acf_answers <- function(subjid,
#' @rawNamespace import(dplyr, except = c(last, first, summarize, src, between))
#' @import data.table
#' @examples
#' \donttest{
#' # Run on a small subset of given data
#' df <- as.data.frame(syngrowth)
#' df <- df[df$subjid %in% unique(df[, "subjid"])[1:5], ]
#' df <- df[df$subjid %in% unique(df[, "subjid"])[1:2], ]
#' clean_df <- cbind(df,
#' "gcr_result" = cleangrowth(df$subjid,
#' df$param,
Expand All @@ -1101,6 +1102,7 @@ acf_answers <- function(subjid,
#' sex = clean_df$sex,
#' measurement = clean_df$measurement,
#' orig.exclude = clean_df$gcr_result)
#' }
adjustcarryforward <- function(subjid,
param,
agedays,
Expand Down
2 changes: 2 additions & 0 deletions R/cdc.R
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ set_cols_first <- function(DT, cols, intersection = TRUE)
#' @importFrom stats approx pnorm qnorm
#' @rawNamespace import(R.utils, except = c(extract))
#' @examples
#' \donttest{
#' # Run on a small subset of given data
#' df <- as.data.frame(syngrowth)
#' df <- df[df$subjid %in% unique(df[, "subjid"])[1:5], ]
Expand All @@ -133,6 +134,7 @@ set_cols_first <- function(DT, cols, intersection = TRUE)
#' # Disabling conversion of all-integer age in months to (age + 0.5)
#' dfc <- simple_bmi(df_wide)
#' df_bmiz <- ext_bmiz(dfc, adjust.integer.age=FALSE)
#' }
ext_bmiz <- function (data,
age = "agem",
wt = "wt",
Expand Down
2 changes: 2 additions & 0 deletions R/growth.R
Original file line number Diff line number Diff line change
Expand Up @@ -1161,12 +1161,14 @@ cleangrowth <- function(subjid,
#' @import data.table
#' @importFrom utils read.csv read.table
#' @examples
#' \donttest{
#' # Return calculating function with all defaults
#' afunc <- read_anthro()
#'
#' # Return calculating function while specifying a path and using only CDC data
#' afunc <- read_anthro(path = system.file("extdata", package = "growthcleanr"),
#' cdc.only = TRUE)
#' }
read_anthro <- function(path = "", cdc.only = FALSE, prelim_infants = FALSE) {
# avoid "no visible bindings" warning
src <- param <- sex <- age <- ret <- m <- NULL
Expand Down
4 changes: 2 additions & 2 deletions R/utils.R
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ recode_sex <- function(input_data,
#' @examples
#' # Run on a small subset of given data
#' df <- as.data.frame(syngrowth)
#' df <- df[df$subjid %in% unique(df[, "subjid"])[1:5], ]
#' df <- df[df$subjid %in% unique(df[, "subjid"])[1:2], ]
#' df <- cbind(df,
#' "gcr_result" = cleangrowth(df$subjid,
#' df$param,
Expand Down Expand Up @@ -332,7 +332,7 @@ longwide <-
#' # Simple usage
#' # Run on a small subset of given data
#' df <- as.data.frame(syngrowth)
#' df <- df[df$subjid %in% unique(df[, "subjid"])[1:5], ]
#' df <- df[df$subjid %in% unique(df[, "subjid"])[1:2], ]
#' df <- cbind(df,
#' "gcr_result" = cleangrowth(df$subjid,
#' df$param,
Expand Down
53 changes: 51 additions & 2 deletions cran-comments.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# CRAN submission growthcleanr 2.2.0
# CRAN submission growthcleanr 2.2.0 (1)

## R CMD check results
There were no ERRORs or WARNINGs.

There was one note:
There was one NOTE:

❯ checking installed package size ... NOTE
installed size is 5.9Mb
Expand All @@ -15,8 +15,57 @@ extdata has been compressed as much as possible -- data in that folder is necess
## Downstream dependencies
There are currently no downstream dependencies for this package.

## CRAN test

We have addressed each of the notes in the test as noted below:

* Maintainer: ‘Carrie Daymont <[email protected]>

Size of tarball: 5529529 bytes

The package has been compressed as much as possible, as noted above -- data included is necessary to run the package.

* NOTE
Examples with CPU (user + system) or elapsed time > 5s
user system elapsed
ext_bmiz 6.911 0.120 0.925
simple_bmi 6.740 0.167 0.783
adjustcarryforward 6.494 0.140 1.179
longwide 5.072 0.135 0.834
Examples with CPU time > 2.5 times elapsed time
user system elapsed ratio
simple_bmi 6.740 0.167 0.783 8.821
read_anthro 2.323 0.060 0.276 8.634
ext_bmiz 6.911 0.120 0.925 7.601
longwide 5.072 0.135 0.834 6.243
adjustcarryforward 6.494 0.140 1.179 5.627

Examples have been reduced in length or set to donttest.

* Running ‘testthat.R’ [230s/74s]
Running R code in ‘testthat.R’ had CPU time 3.1 times elapsed time

Tests have been set to not run on CRAN.

# Previous Submissions

# CRAN submission growthcleanr 2.2.0

## R CMD check results
There were no ERRORs or WARNINGs.

There was one note:

❯ checking installed package size ... NOTE
installed size is 5.9Mb
sub-directories of 1Mb or more:
extdata 5.0Mb

extdata has been compressed as much as possible -- data in that folder is necessary to run the package.

## Downstream dependencies
There are currently no downstream dependencies for this package.

# CRAN submission growthcleanr 2.1.1

## R CMD check results
Expand Down
2 changes: 1 addition & 1 deletion docs/articles/adult-algorithm.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/configuration.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/developer-guidelines.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/installation.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/large-data-sets.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/next-steps.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/output.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/prelim-infants-algorithm.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/quickstart.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/usage.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/utilities.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ articles:
quickstart: quickstart.html
usage: usage.html
utilities: utilities.html
last_built: 2023-09-13T23:26Z
last_built: 2023-09-15T16:20Z

6 changes: 4 additions & 2 deletions docs/reference/adjustcarryforward.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion docs/reference/ext_bmiz.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/longwide.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit cd1883f

Please sign in to comment.