COXT02
Table 1 (Default) Multi-Variable Cox Regression Model Table 1.
coxt02.Rd
The COXT02
table follows the same principles as the general Cox model analysis
and produces the estimates for each of the covariates included in the model
(usually the main effects without interaction terms).
Usage
coxt02_main(
adam_db,
arm_var = "ARM",
time_var = "AVAL",
event_var = "EVENT",
covariates = c("SEX", "RACE", "AAGE"),
strata = NULL,
lbl_vars = "Effect/Covariate Included in the Model",
...
)
coxt02_pre(adam_db, ...)
coxt02_post(tlg, prune_0 = FALSE, ...)
coxt02
Arguments
- adam_db
(
list
ofdata.frames
) object containing theADaM
datasets- arm_var
(
string
) the arm variable used for arm splitting.- time_var
(
string
) the time variable in a Cox proportional hazards regression model.- event_var
(
string
) the event variable in a Cox proportional hazards regression model.- covariates
(
character
) will be fitted and the corresponding effect will be estimated.- strata
(
character
) will be fitted for the stratified analysis.- lbl_vars
(
string
) text label for the a Cox regression model variables.- ...
Further arguments passed to
tern::control_coxreg()
.- tlg
(
TableTree
,Listing
orggplot
) object typically produced by amain
function.- prune_0
(
flag
) remove 0 count rows
Details
The reference arm will always the first level of
arm_var
. Please change the level if you want to change the reference arms.The table allows confidence level to be adjusted, default is 2-sided 5%.
The stratified analysis is with DISCRETE tie handling (equivalent to
tern::control_coxreg(ties = "exact")
in R).Model includes treatment plus specified covariate(s) as factor(s) or numeric(s), with
"SEX"
,"RACE"
and"AAGE"
as default candidates.The selection of the covariates and whether or not there is a selection process (vs. a fixed, pre-specified list) needs to be specified in the DAP.
For pairwise comparisons using the hazard ratio, the value for the control group is the denominator.
Keep zero-count rows unless overridden with
prune_0 = TRUE
.
Functions
coxt02_main()
: Main TLG functioncoxt02_pre()
: Preprocessingcoxt02_post()
: Postprocessing
Note
adam_db
object must contain anadtte
table with"PARAMCD"
,"ARM"
,"AVAL"
,"CNSR
, and the columns specified by"covariates"
which is denoted asc("SEX", "RACE", "AAGE")
by default.
Examples
library(dplyr)
library(dunlin)
proc_data <- log_filter(syn_data, PARAMCD == "CRSD", "adtte")
run(coxt02, proc_data)
#> Effect/Covariate Included in the Model Hazard Ratio 95% CI p-value
#> —————————————————————————————————————————————————————————————————————————————————————————————
#> Treatment:
#> Description of Planned Arm (reference = A: Drug X) <0.0001
#> B: Placebo 1.45 (1.07, 1.98) 0.0176
#> C: Combination 2.49 (1.84, 3.37) <0.0001
#> Covariate:
#> Sex (reference = F)
#> M 0.99 (0.78, 1.27) 0.9564
#> RACE (reference = AMERICAN INDIAN OR ALASKA NATIVE) 0.9134
#> ASIAN 0.85 (0.49, 1.46) 0.5568
#> BLACK OR AFRICAN AMERICAN 0.85 (0.48, 1.50) 0.5673
#> WHITE 0.91 (0.51, 1.63) 0.7579
#> Age (yr)
#> All 0.99 (0.97, 1.01) 0.2501
run(coxt02, proc_data, covariates = c("SEX", "AAGE"), strata = c("RACE"), conf_level = 0.90)
#> Effect/Covariate Included in the Model Hazard Ratio 90% CI p-value
#> ————————————————————————————————————————————————————————————————————————————————————————————
#> Treatment:
#> Description of Planned Arm (reference = A: Drug X) <0.0001
#> B: Placebo 1.45 (1.12, 1.88) 0.0192
#> C: Combination 2.51 (1.94, 3.24) <0.0001
#> Covariate:
#> Sex (reference = F)
#> M 1.00 (0.81, 1.23) 0.9692
#> Age (yr)
#> All 0.99 (0.97, 1.00) 0.1956