diff --git a/DESCRIPTION b/DESCRIPTION index 5521390..c0e997b 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,14 +1,14 @@ Package: growthcleanr Type: Package Title: Data Cleaner for Anthropometric Measurements -Version: 2.0.2 +Version: 2.0.3 Authors@R: c( - person("Daymont","Carrie", email = "cdaymont@pennstatehealth.psu.edu", role = "aut"), + person("Daymont","Carrie", email = "cdaymont@pennstatehealth.psu.edu", role = c("ctb","cre")), person("Grundmeier","Robert", role = "aut"), person("Miller","Jeffrey", role = "aut"), person("Campos","Diego", role = "aut"), person("Chudnov","Dan", role = "ctb"), - person("De los Santos","Hannah", email = "hdelossantos@mitre.org", role = c("ctb","cre")), + person("De los Santos","Hannah", email = "hdelossantos@mitre.org", role = c("ctb")), person("Cao","Lusha", role = "ctb"), person("Silva","Steffani", role = "ctb"), person("Zhang","Hanzhe", role = "ctb"), diff --git a/NEWS.md b/NEWS.md index dd21b01..cfdecca 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,3 +1,14 @@ +# growthcleanr 2.0.3 - 2022-11-01 + +## Added + +- CRAN release checklist now added under Developer Guidelines vignette (#99) + +## Changed + +- All possible levels for `cleangrowth()` output factor now enumerated +- Updated maintainer to Carrie Daymont + # growthcleanr 2.0.2 - 2022-09-13 ## Added diff --git a/R/growth.R b/R/growth.R index a04d53c..ab47195 100644 --- a/R/growth.R +++ b/R/growth.R @@ -204,7 +204,7 @@ cleangrowth <- function(subjid, # constants for pediatric # enumerate the different exclusion levels - exclude.levels <- c( + exclude.levels.peds <- c( 'Include', 'Unit-Error-High', 'Unit-Error-Low', @@ -235,6 +235,29 @@ cleangrowth <- function(subjid, 'Exclude-Too-Many-Errors-Other-Parameter' ) + exclude.levels.adult <- c( + "Include", + "Exclude-Adult-BIV", + "Exclude-Adult-Hundreds", + "Exclude-Adult-Unit-Errors", + "Exclude-Adult-Transpositions", + "Exclude-Adult-Weight-Cap-Identical", + "Exclude-Adult-Weight-Cap", + "Exclude-Adult-Swapped-Measurements", + "Exclude-Adult-Identical-Same-Day", + "Exclude-Adult-Extraneous-Same-Day", + "Exclude-Adult-Distinct-Pairs", + "Exclude-Adult-Distinct-3-Or-More", + "Exclude-Adult-EWMA-Extreme", + "Exclude-Adult-Distinct-Ordered-Pairs", + "Exclude-Adult-EWMA-Moderate", + "Exclude-Adult-Possibly-Impacted-By-Weight-Cap", + "Exclude-Adult-Distinct-Single", + "Exclude-Adult-Too-Many-Errors" + ) + + exclude.levels <- base::union(exclude.levels.peds, exclude.levels.adult) + # if there's no pediatric data, no need to go through this rigamarole if (nrow(data.all) > 0){ @@ -665,8 +688,7 @@ cleangrowth <- function(subjid, exclude = c(as.character(ret.df$exclude), res$result), mean_sde = c(rep(NA, nrow(ret.df)), res$mean_sde) ) - full_out[, exclude := factor(exclude, levels = unique(c(exclude.levels, - unique(exclude))))] + full_out[, exclude := factor(exclude, levels = exclude.levels)] full_out <- full_out[order(line),] # remove column added for keeping track full_out[, line := NULL] diff --git a/README.Rmd b/README.Rmd index 0e3bed1..e611469 100644 --- a/README.Rmd +++ b/README.Rmd @@ -102,6 +102,7 @@ The rest of this documentation includes: notes and suggestions for running `growthcleanr` with large data sources - [Next steps](https://carriedaymont.github.io/growthcleanr/articles/next-steps.html), notes on potential enhancements to the pediatric and adult algorithms +- [Developer guidelines](https://carriedaymont.github.io/growthcleanr/articles/developer-guidelines.html), advice for contributors to this package, including a CRAN release checklist ## Changes diff --git a/README.md b/README.md index d4e7232..01d3a0c 100644 --- a/README.md +++ b/README.md @@ -103,6 +103,10 @@ The rest of this documentation includes: - [Next steps](https://carriedaymont.github.io/growthcleanr/articles/next-steps.html), notes on potential enhancements to the pediatric and adult algorithms +- [Developer + guidelines](https://carriedaymont.github.io/growthcleanr/articles/developer-guidelines.html), + advice for contributors to this package, including a CRAN release + checklist ## Changes diff --git a/_pkgdown.yml b/_pkgdown.yml index 7934b0f..8a0c688 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -19,6 +19,7 @@ articles: - utilities - large-data-sets - next-steps + - developer-guidelines reference: - title: "Cleaning height and weight observations" diff --git a/cran-comments.md b/cran-comments.md index f05f783..16d8dd9 100644 --- a/cran-comments.md +++ b/cran-comments.md @@ -1,4 +1,4 @@ -# CRAN submission growthcleanr 2.0.2 (1) +# CRAN submission growthcleanr 2.0.3 ## R CMD check results There were no ERRORs, WARNINGs, or NOTEs. @@ -6,8 +6,18 @@ There were no ERRORs, WARNINGs, or NOTEs. ## Downstream dependencies There are currently no downstream dependencies for this package. + + # Previous Submissions +# CRAN submission growthcleanr 2.0.2 (1) + +## R CMD check results +There were no ERRORs, WARNINGs, or NOTEs. + +## Downstream dependencies +There are currently no downstream dependencies for this package. + # CRAN submission growthcleanr 2.0.1 (6) ## R CMD check results diff --git a/docs/404.html b/docs/404.html index c4798da..836e017 100644 --- a/docs/404.html +++ b/docs/404.html @@ -18,7 +18,7 @@
- +