check_ex_exdose_exoccur {sdtmchecks}R Documentation

Check for Missing EXDOSE.

Description

This checks looks for missing EXDOSE values when EXOCCUR="Y" or when EXOCCUR does not exist. It could be for a specified drug/treatment, or for all drugs/treatments in the dataset

Usage

check_ex_exdose_exoccur(EX, drug = NULL)

Arguments

EX

Exposure SDTM dataset with variables USUBJID, EXTRT, EXSTDTC, EXDOSE, and optional variable EXOCCUR and optional variable VISIT

drug

Drug name for EXTRT; used to subset the dataset. Default value is NULL (i.e. no filtering by drug)

Value

Boolean value for whether the check passed or failed, with 'msg' attribute if the test failed

Author(s)

Will Harris, Pasha Foroudi

Examples


EX <- data.frame(
 USUBJID = 1:3,
 EXSEQ   = 1:3,
 EXSTDTC = 1:3,
 EXTRT   = c(1,2,NA),
 EXOCCUR = "Y",
 EXDOSE  = 1:3,
 VISIT = c("CYCLE 1 DAY 1", "CYCLE 2 DAY 1", "CYCLE 3 DAY 1")
)

check_ex_exdose_exoccur(EX)

EX$EXDOSE[3]=NA
check_ex_exdose_exoccur(EX)

EX$EXVISIT = NULL
check_ex_exdose_exoccur(EX)

EX$EXDOSE = NULL
check_ex_exdose_exoccur(EX)



[Package sdtmchecks version 1.0.0 Index]