
strata(..., na.group=FALSE, shortlabel=FALSE, sep=', ')
TRUE
, then missing values are treated as a
distinct level of each variable.TRUE
omit variable names from resulting
factor labelsinteraction
function,
but for the labeling of the factors (strata
is more verbose).coxph
, interaction
a<-factor(rep(1:3,4))
b<-factor(rep(1:4,3))
levels(strata(a))
levels(strata(a,b,shortlabel=TRUE))
coxph(Surv(futime, fustat) ~ age + strata(rx), data=ovarian)
Run the code above in your browser using DataLab