Checks that a dataset contains all required variables for MRCT simulation functions and reports any issues. Required variables include outcome (tte, event), treatment (treat), continuous covariates (age, bm), and factor covariates (male, histology, prior_treat, regA).
Details
Required Variables
The function checks for the following variables:
Outcome: tte (time-to-event), event (0/1 indicator)
Treatment: treat (0/1 indicator)
Continuous: age, bm (biomarker)
Factor: male (0/1), histology, prior_treat (0/1), regA (0/1)
The function also validates variable types and value ranges.
See also
create_dgm_for_mrct for creating DGM from validated data
Examples
if (FALSE) { # \dontrun{
# Check if dataset is ready for MRCT simulations
is_valid <- validate_mrct_data(df.case)
if (!is_valid) {
stop("Please fix data issues before running simulations")
}
} # }