From 9aa991fbeca67f8a1994d93e35e21d983b2b588c Mon Sep 17 00:00:00 2001 From: Eli Miller Date: Wed, 20 Mar 2024 21:16:18 -0500 Subject: [PATCH] Doc updates per #261 --- R/split.R | 4 +--- R/xportr-package.R | 2 +- R/xportr.R | 3 +-- man/metadata.Rd | 3 +-- man/xportr.Rd | 3 +-- man/xportr_df_label.Rd | 3 +-- man/xportr_format.Rd | 3 +-- man/xportr_label.Rd | 3 +-- man/xportr_length.Rd | 3 +-- man/xportr_order.Rd | 3 +-- man/xportr_split.Rd | 4 +--- man/xportr_type.Rd | 3 +-- man/xportr_write.Rd | 3 +-- 13 files changed, 13 insertions(+), 27 deletions(-) diff --git a/R/split.R b/R/split.R index 74b84257..a0fab294 100644 --- a/R/split.R +++ b/R/split.R @@ -21,15 +21,13 @@ #' @export #' #' @examples -#' data("adsl_xportr") -#' adsl <- adsl_xportr #' #' adlb <- data.frame( #' USUBJID = c(1001, 1002, 1003), #' LBCAT = c("HEMATOLOGY", "HEMATOLOGY", "CHEMISTRY") #' ) #' -#' adsl <- xportr_split(adsl, "LBCAT") +#' adlb <- xportr_split(adlb, "LBCAT") xportr_split <- function(.df, split_by = NULL) { attr(.df, "_xportr.split_by_") <- split_by diff --git a/R/xportr-package.R b/R/xportr-package.R index 417e58b8..5fc37e08 100644 --- a/R/xportr-package.R +++ b/R/xportr-package.R @@ -127,7 +127,7 @@ globalVariables(c( "abbr_parsed", "abbr_stem", "adj_orig", "adj_parsed", "col_pos", "dict_varname", "lower_original_varname", "my_minlength", "num_st_ind", "original_varname", "renamed_n", "renamed_var", "use_bundle", "viable_start", "type.x", "type.y", - "variable", "length.x", "lenght.y", "e", "length_df", "length_meta" + "variable", "length.x", "lenght.y", "e", "length_df", "length_meta", ".env" )) # The following block is used by usethis to automatically manage diff --git a/R/xportr.R b/R/xportr.R index d5a046cd..cab3db08 100644 --- a/R/xportr.R +++ b/R/xportr.R @@ -3,8 +3,7 @@ #' @param .df A data frame of CDISC standard. #' @param var_metadata A data frame containing variable level metadata #' @param domain Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -#' the metadata object. If none is passed, then name of the dataset passed as -#' .df will be used. +#' the metadata object. #' @param verbose The action this function takes when an action is taken on the #' dataset or function validation finds an issue. See 'Messaging' section for #' details. Options are 'stop', 'warn', 'message', and 'none' diff --git a/man/metadata.Rd b/man/metadata.Rd index cd286905..258d1687 100644 --- a/man/metadata.Rd +++ b/man/metadata.Rd @@ -13,8 +13,7 @@ xportr_metadata(.df, metadata = NULL, domain = NULL, verbose = NULL) 'Metadata' section for details.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{verbose}{The action this function takes when an action is taken on the dataset or function validation finds an issue. See 'Messaging' section for diff --git a/man/xportr.Rd b/man/xportr.Rd index bc5dcf97..1a9acd51 100644 --- a/man/xportr.Rd +++ b/man/xportr.Rd @@ -22,8 +22,7 @@ xportr( \item{df_metadata}{A data frame containing dataset level metadata.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{verbose}{The action this function takes when an action is taken on the dataset or function validation finds an issue. See 'Messaging' section for diff --git a/man/xportr_df_label.Rd b/man/xportr_df_label.Rd index 5f95d771..e3da9800 100644 --- a/man/xportr_df_label.Rd +++ b/man/xportr_df_label.Rd @@ -13,8 +13,7 @@ xportr_df_label(.df, metadata = NULL, domain = NULL, metacore = deprecated()) details.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{metacore}{\ifelse{html}{\href{https://lifecycle.r-lib.org/articles/stages.html#deprecated}{\figure{lifecycle-deprecated.svg}{options: alt='[Deprecated]'}}}{\strong{[Deprecated]}} Previously used to pass metadata now renamed with \code{metadata}} diff --git a/man/xportr_format.Rd b/man/xportr_format.Rd index e45f66dc..3ddcca4e 100644 --- a/man/xportr_format.Rd +++ b/man/xportr_format.Rd @@ -19,8 +19,7 @@ xportr_format( 'Metadata' section for details.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{verbose}{The action this function takes when an action is taken on the dataset or function validation finds an issue. See 'Messaging' section for diff --git a/man/xportr_label.Rd b/man/xportr_label.Rd index a61e0583..8e637975 100644 --- a/man/xportr_label.Rd +++ b/man/xportr_label.Rd @@ -19,8 +19,7 @@ xportr_label( 'Metadata' section for details.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{verbose}{The action this function takes when an action is taken on the dataset or function validation finds an issue. See 'Messaging' section for diff --git a/man/xportr_length.Rd b/man/xportr_length.Rd index c3180a71..f60ee667 100644 --- a/man/xportr_length.Rd +++ b/man/xportr_length.Rd @@ -20,8 +20,7 @@ xportr_length( 'Metadata' section for details.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{verbose}{The action this function takes when an action is taken on the dataset or function validation finds an issue. See 'Messaging' section for diff --git a/man/xportr_order.Rd b/man/xportr_order.Rd index 03617d4f..1cc2cc08 100644 --- a/man/xportr_order.Rd +++ b/man/xportr_order.Rd @@ -19,8 +19,7 @@ xportr_order( 'Metadata' section for details.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{verbose}{The action this function takes when an action is taken on the dataset or function validation finds an issue. See 'Messaging' section for diff --git a/man/xportr_split.Rd b/man/xportr_split.Rd index 5c9da890..34223a5f 100644 --- a/man/xportr_split.Rd +++ b/man/xportr_split.Rd @@ -29,13 +29,11 @@ with a number for uniqueness. These files should be noted in the Reviewer Guides CDISC guidance to note how you split your files. } \examples{ -data("adsl_xportr") -adsl <- adsl_xportr adlb <- data.frame( USUBJID = c(1001, 1002, 1003), LBCAT = c("HEMATOLOGY", "HEMATOLOGY", "CHEMISTRY") ) -adsl <- xportr_split(adsl, "LBCAT") +adlb <- xportr_split(adlb, "LBCAT") } diff --git a/man/xportr_type.Rd b/man/xportr_type.Rd index 05489fcf..db756a56 100644 --- a/man/xportr_type.Rd +++ b/man/xportr_type.Rd @@ -19,8 +19,7 @@ xportr_type( 'Metadata' section for details.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{verbose}{The action this function takes when an action is taken on the dataset or function validation finds an issue. See 'Messaging' section for diff --git a/man/xportr_write.Rd b/man/xportr_write.Rd index bde66844..f19e57be 100644 --- a/man/xportr_write.Rd +++ b/man/xportr_write.Rd @@ -23,8 +23,7 @@ used as \code{xpt} name.} details.} \item{domain}{Appropriate CDISC dataset name, e.g. ADAE, DM. Used to subset -the metadata object. If none is passed, then name of the dataset passed as -.df will be used.} +the metadata object.} \item{strict_checks}{If TRUE, xpt validation will report errors and not write out the dataset. If FALSE, xpt validation will report warnings and continue