diff --git a/DESCRIPTION b/DESCRIPTION index 74faec8..1946ff6 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: nhanesA Version: 0.6.5.2 -Date: 2019-06-22 +Date: 2021-01-24 Title: NHANES Data Retrieval Author: Christopher J. Endres Maintainer: Christopher J. Endres @@ -24,4 +24,4 @@ Suggests: knitr, rmarkdown VignetteBuilder: knitr -RoxygenNote: 6.1.1 +RoxygenNote: 7.1.1 diff --git a/R/nhanes.R b/R/nhanes.R index 923c3e4..087229c 100644 --- a/R/nhanes.R +++ b/R/nhanes.R @@ -54,8 +54,8 @@ nh_years['2015'] <- "2015-2016" nh_years['2016'] <- "2015-2016" nh_years['2017'] <- "2017-2018" nh_years['2018'] <- "2017-2018" -#nh_years['2019'] <- "2019-2020" -#nh_years['2020'] <- "2019-2020" +nh_years['2019'] <- "2019-2020" +nh_years['2020'] <- "2019-2020" # Continuous NHANES table names have a letter suffix that indicates the collection interval data_idx <- list() @@ -72,7 +72,7 @@ data_idx["G"] <- '2011-2012' data_idx["H"] <- '2013-2014' data_idx["I"] <- '2015-2016' data_idx["J"] <- '2017-2018' -#data_idx["K"] <- '2019-2020' +data_idx["K"] <- '2019-2020' anomalytables2005 <- c('CHLMD_DR', 'SSUECD_R', 'HSV_DR') diff --git a/man/nhanesSearch.Rd b/man/nhanesSearch.Rd index cc4883b..41aea92 100644 --- a/man/nhanesSearch.Rd +++ b/man/nhanesSearch.Rd @@ -4,9 +4,17 @@ \alias{nhanesSearch} \title{Perform a search over the comprehensive NHANES variable list.} \usage{ -nhanesSearch(search_terms = NULL, exclude_terms = NULL, - data_group = NULL, ignore.case = FALSE, ystart = NULL, - ystop = NULL, includerdc = FALSE, nchar = 100, namesonly = FALSE) +nhanesSearch( + search_terms = NULL, + exclude_terms = NULL, + data_group = NULL, + ignore.case = FALSE, + ystart = NULL, + ystop = NULL, + includerdc = FALSE, + nchar = 100, + namesonly = FALSE +) } \arguments{ \item{search_terms}{List of terms or keywords.} diff --git a/man/nhanesSearchTableNames.Rd b/man/nhanesSearchTableNames.Rd index 930df88..be8526e 100644 --- a/man/nhanesSearchTableNames.Rd +++ b/man/nhanesSearchTableNames.Rd @@ -4,8 +4,14 @@ \alias{nhanesSearchTableNames} \title{Search for matching table names} \usage{ -nhanesSearchTableNames(pattern = NULL, ystart = NULL, ystop = NULL, - includerdc = FALSE, nchar = 100, details = FALSE) +nhanesSearchTableNames( + pattern = NULL, + ystart = NULL, + ystop = NULL, + includerdc = FALSE, + nchar = 100, + details = FALSE +) } \arguments{ \item{pattern}{Pattern of table names to match} diff --git a/man/nhanesSearchVarName.Rd b/man/nhanesSearchVarName.Rd index 20dd8ee..0ccca18 100644 --- a/man/nhanesSearchVarName.Rd +++ b/man/nhanesSearchVarName.Rd @@ -4,8 +4,14 @@ \alias{nhanesSearchVarName} \title{Search for tables that contain a specified variable.} \usage{ -nhanesSearchVarName(varname = NULL, ystart = NULL, ystop = NULL, - includerdc = FALSE, nchar = 100, namesonly = TRUE) +nhanesSearchVarName( + varname = NULL, + ystart = NULL, + ystop = NULL, + includerdc = FALSE, + nchar = 100, + namesonly = TRUE +) } \arguments{ \item{varname}{Name of variable to match.} diff --git a/man/nhanesTableVars.Rd b/man/nhanesTableVars.Rd index 77635da..3c0ec82 100644 --- a/man/nhanesTableVars.Rd +++ b/man/nhanesTableVars.Rd @@ -4,8 +4,13 @@ \alias{nhanesTableVars} \title{Displays a list of variables in the specified NHANES table.} \usage{ -nhanesTableVars(data_group, nh_table, details = FALSE, nchar = 100, - namesonly = FALSE) +nhanesTableVars( + data_group, + nh_table, + details = FALSE, + nchar = 100, + namesonly = FALSE +) } \arguments{ \item{data_group}{The type of survey (DEMOGRAPHICS, DIETARY, EXAMINATION, LABORATORY, QUESTIONNAIRE). diff --git a/man/nhanesTables.Rd b/man/nhanesTables.Rd index 13f931f..4de2c96 100644 --- a/man/nhanesTables.Rd +++ b/man/nhanesTables.Rd @@ -4,8 +4,14 @@ \alias{nhanesTables} \title{Returns a list of table names for the specified survey group.} \usage{ -nhanesTables(data_group, year, nchar = 100, details = FALSE, - namesonly = FALSE, includerdc = FALSE) +nhanesTables( + data_group, + year, + nchar = 100, + details = FALSE, + namesonly = FALSE, + includerdc = FALSE +) } \arguments{ \item{data_group}{The type of survey (DEMOGRAPHICS, DIETARY, EXAMINATION, LABORATORY, QUESTIONNAIRE). diff --git a/man/nhanesTranslate.Rd b/man/nhanesTranslate.Rd index 3b3015b..c43dce3 100644 --- a/man/nhanesTranslate.Rd +++ b/man/nhanesTranslate.Rd @@ -2,10 +2,17 @@ % Please edit documentation in R/nhanes.R \name{nhanesTranslate} \alias{nhanesTranslate} -\title{Display code translation information for the specified table.} +\title{Display code translation information.} \usage{ -nhanesTranslate(nh_table, colnames = NULL, data = NULL, nchar = 32, - mincategories = 2, details = FALSE, dxa = FALSE) +nhanesTranslate( + nh_table, + colnames = NULL, + data = NULL, + nchar = 32, + mincategories = 2, + details = FALSE, + dxa = FALSE +) } \arguments{ \item{nh_table}{The name of the NHANES table to retrieve.} @@ -28,8 +35,8 @@ Truncate the length by setting nchar (default = 32).} The code translation table (or translated data frame when data is defined). } \description{ -Returns code translations which is especially useful for categorical tables, -which includes most NHANES tables. +Returns code translations for categorical variables, +which appear in most NHANES tables. } \details{ Code translation tables are retrieved via webscraping using rvest. diff --git a/nhanes.Rproj b/nhanes.Rproj index bf73ff4..5742640 100644 --- a/nhanes.Rproj +++ b/nhanes.Rproj @@ -15,5 +15,5 @@ LaTeX: pdfLaTeX BuildType: Package PackageUseDevtools: Yes PackageInstallArgs: --no-multiarch --with-keep.source -PackageCheckArgs: --as-cran +PackageCheckArgs: --as-cran --run-donttest PackageRoxygenize: rd,collate,namespace,vignette