diff --git a/NEWS.md b/NEWS.md index 44bd475a..e8d63f0a 100644 --- a/NEWS.md +++ b/NEWS.md @@ -58,6 +58,8 @@ done to make the use of xportr functions more explicit. (#182) * Additional guidance for options added in deep dive vignette (#81) +* Added a vignette about standards in different agencies (#206) + * Removed non-user facing function documentation (#192) ## Miscellaneous diff --git a/_pkgdown.yml b/_pkgdown.yml index acb1779b..2bdcf856 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -52,3 +52,4 @@ articles: navbar: ~ contents: - deepdive + - agency_standards diff --git a/inst/WORDLIST b/inst/WORDLIST index c0d8ae96..6a54d44d 100644 --- a/inst/WORDLIST +++ b/inst/WORDLIST @@ -1,13 +1,9 @@ ADAE ADSL ADaM -adlb -AE Atorus -BMI CDISC Codelist -Completers DATETIMEw DATEw DAw @@ -17,17 +13,18 @@ DM DNw DTw DXw -Didenko -fda +Datetime GSK HHMM JPT LXw LZw MMDDYYw -MMSE +MedDRA +NMPA ORCID PHUSE +PMDA Pharma Repostiory SAS's @@ -40,10 +37,8 @@ TMw TRTDUR TXw TZw -Thanikachalam +Transcoding Trt -Vignesh -Vis WEEKDATEw XPT YYMMDDw @@ -55,6 +50,9 @@ datetime deliverables df durationdatetime +eSubmission +fda +https incompletedatetime intervaldatetime iso @@ -72,8 +70,7 @@ sas sdrg validator validators +www xportr's +xportr’s xpt -https -lbcat -www diff --git a/man/figures/fda.jpg b/man/figures/fda.jpg new file mode 100644 index 00000000..bab70da2 Binary files /dev/null and b/man/figures/fda.jpg differ diff --git a/man/figures/nmpa.png b/man/figures/nmpa.png new file mode 100644 index 00000000..41464a13 Binary files /dev/null and b/man/figures/nmpa.png differ diff --git a/man/figures/pmda.png b/man/figures/pmda.png new file mode 100644 index 00000000..f3b322f2 Binary files /dev/null and b/man/figures/pmda.png differ diff --git a/man/figures/xpt.png b/man/figures/xpt.png new file mode 100644 index 00000000..91a3a71e Binary files /dev/null and b/man/figures/xpt.png differ diff --git a/vignettes/agency_standards.Rmd b/vignettes/agency_standards.Rmd new file mode 100644 index 00000000..b7ad9d05 --- /dev/null +++ b/vignettes/agency_standards.Rmd @@ -0,0 +1,254 @@ +--- +title: "Standards in Different Regulatory Agencies" +output: + rmarkdown::html_vignette: + toc: true + check_title: TRUE +vignette: > + %\VignetteIndexEntry{Standards in Different Regulatory Agencies} + %\VignetteEngine{knitr::rmarkdown} + %\VignetteEncoding{UTF-8} +--- + +# Motivation + +The `xportr` package is designed to help clinical programmers create `CDISC` compliant `xpt` files. +It provides the functionality to associate metadata information to a local R data frame, perform data set level validation checks, and convert into a transport v5 file (`xpt`). +However, technical requirements related to the `xpt` files can change across different regulatory agencies. +This vignette aims to start to provide a clear and concise summary of the differences between the agencies for the `xpt` files. Further updates will come with later package releases. + + +The following section will delve into various technical specifications as per [FDA](https://www.fda.gov/media/153632/download), [NMPA](https://www.nmpa.gov.cn/directory/web/nmpa/images/obbSqc7vwdm0ssrU0enKb7dtd29u9a4tbzUrdTyo6jK1NDQo6mhty5wZGY=.pdf), and [PMDA](https://www.pmda.go.jp/files/000247157.pdf) guidelines. + + +### File name - character + +#### XPT + +The first character must be an English letter (A, B, C, . . ., Z) or underscore (_). Subsequent characters can be letters, numeric digits (0, 1, . . ., 9), or underscores. +You can use uppercase or lowercase letters. +Blanks cannot appear in SAS names. +Special characters, except for the underscore, are not allowed. + +#### FDA + +Dataset in the transport file should be named the same as the transport file. +Variable names, as well as variable and dataset labels should include American Standard Code for Information Interchange (ASCII) text codes only. +Dataset names should contain only lowercase letters, numbers, and must start with a letter. + +#### NMPA + +The file name and the dataset name must be the same for the SDTM and ADaM datasets. +The Japanese dataset and alphanumeric dataset must be identical in structure, except for the data lengths of the Japanese items and the corresponding alphanumeric character sequence + +#### PMDA + +Information has not yet been collected. + +*** + +### File name - length + +#### XPT + +maximum length of 8 bytes + +#### FDA + +8 characters + +#### NMPA + +\- + +#### PMDA + +Information has not yet been collected. + +*** + +### Variable name + +#### XPT + +The name can contain letters of the Latin alphabet, numerals, or underscores. +The name cannot contain blanks or special characters except for the underscore. +The name must begin with a letter of the Latin alphabet (A–Z, a–z) or the underscore. + +#### FDA + +Variable names, as well as variable and dataset labels should include American Standard Code for Information Interchange (ASCII) text codes only. +Variable names should contain only uppercase letters, numbers, and must start with a letter + +#### NMPA + +The Japanese dataset and alphanumeric dataset must be identical in structure, except for the data lengths of the Japanese items and the corresponding alphanumeric character sequence + +#### PMDA + +Information has not yet been collected. + +*** + +### Variable length + +#### XPT + +8 bytes + +#### FDA + +8 characters + +#### NMPA + +\- + +#### PMDA + +Information has not yet been collected. + +*** + +### Label character + +#### XPT + +\- + +#### FDA + +Variable names, as well as variable and dataset labels should include American Standard Code for Information Interchange (ASCII) text codes only. +Do not submit study data with the following special characters in variable and dataset labels: +1. Unbalanced apostrophe, e.g., "Parkinson's" +2. Unbalanced single and double quotation marks +3. Unbalanced parentheses, braces or brackets, e.g.,`(`, `{`and `[` + +#### NMPA + +The Japanese dataset and alphanumeric dataset must be identical in structure, except for the data lengths of the Japanese items and the corresponding alphanumeric character sequence + +#### PMDA + +For eSubmission in China, one of the requirements is to translate the foreign language data package (e.g., English) to Chinese. Variable labels, dataset labels, MedDRA, WHO Drug terms, primary endpoint-related code lists, etc., need to be translated from English to Chinese. + +*** + +### Label length + +#### XPT + +40 bytes + +#### FDA + +40 characters + +#### NMPA + +\- + +#### PMDA + +Information has not yet been collected. + +*** + +### Values character + +#### XPT + +\- + +#### FDA + +Variable values are the most broadly compatible with software and operating systems when they are restricted to ASCII text codes (printable values below 128). Use UTF-8 for extending character sets; however, the use of extended mappings is not recommended. Transcoding errors, variable length errors, and lack of software support for multi byte UTF-8 encodings can result in incorrect character display and variable value truncation. + +#### NMPA + +If variables had been collected in Japanese and there is a risk of losing certain information by translating it into English, the descriptions in Japanese are necessary and appropriate, and data written in Japanese (hereinafter referred to as Japanese data) may be submitted. In the Japanese dataset, only the Japanese items should be Japanese and the rest should be alphanumeric(=ASCII) data, similar to that in the alphanumeric dataset. + +#### PMDA + +For eSubmission in China, one of the requirements is to translate the foreign language data package (e.g., English) to Chinese. Variable labels, dataset labels, MedDRA, WHO Drug terms, primary endpoint-related code lists, etc., need to be translated from English to Chinese. + + +*** + +### Values length + +#### XPT + +200 bytes + +#### FDA + +The allotted length for each column containing character (text) data should be set to the maximum length of the variable used across all datasets in the study except for supplementary qualification datasets. + +#### NMPA + +\- + +#### PMDA + +Information has not yet been collected. + +*** + +### Format + +#### XPT + +SAS format + +#### FDA + +SAS format + +#### NMPA + +\- + +#### PMDA + +Information has not yet been collected. + +*** + +### Type + +#### XPT + +Numeric and character + +#### FDA + +\- + +#### NMPA + +\- + +#### PMDA + +\- + +*** + +### File size + +#### XPT + +\- + +#### FDA + +5 GB + +#### NMPA + +To be consulted if sponsors have datasets >= 5 GB No requirement to split datasets + +#### PMDA + +Information has not yet been collected.