View source: R/check_cm_cmdecod.R
check_cm_cmdecod | R Documentation |
This check looks for missing CMDECOD values
check_cm_cmdecod(CM, preproc = identity, ...)
CM |
Concomitant Medications SDTM dataset with variables USUBJID, CMTRT, CMDECOD |
preproc |
An optional company specific preprocessing script |
... |
Other arguments passed to methods |
boolean value if check failed or passed with 'msg' attribute if the test failed
Lei Zhao, Stella Banjo (HackR 2021)
CM <- data.frame(
USUBJID = 1:5,
DOMAIN = rep("CM", 5),
CMTRT = rep("DRUG TERM", 5),
CMDECOD = rep("CODED DRUG TERM", 5),
CMSTDTC = 1:5,
CMENDTC = 1:5,
CMCAT = "CONCOMITANT MEDICATIONS",
CMSPID = c("FORMNAME-R:13/L:13XXXX",
"FORMNAME-R:16/L:16XXXX",
"FORMNAME-R:2/L:2XXXX",
"FORMNAME-R:19/L:19XXXX",
"FORMNAME-R:5/L:5XXXX"),
stringsAsFactors=FALSE
)
check_cm_cmdecod(CM)
CM$CMDECOD[1] = NA
CM$CMDECOD[2] = "NA"
CM$CMDECOD[3:5] = ""
check_cm_cmdecod(CM)
check_cm_cmdecod(CM,preproc=roche_derive_rave_row)
CM$CMDECOD <- NULL
check_cm_cmdecod(CM)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.