4
votes

I have run Cox regression using the survival package to calculate mortality hazard ratio of an exposure A. I have found that the age variable violated the proportional hazard assumption (with cox.zph) and used strata(age)to stratify age in further models.

I need a parameter estimate of the age variable, as well as the variance and the matrix of covariance (to calculate Rate Advancement Periods)... And I don't know where to find them!

Am I missing something or am I misunderstanding what strata is doing?


Here is a reproducible example, using the lung data from the survival package.

library(survival)    

I create the survival object and do a first Cox regression with non-stratified age variable.

lung$SurvObj <- with(lung, Surv(time, status == 2))
coxreg1 <- coxph(SurvObj ~ age + sex, data =  lung)  

So, I get coefficients, variance, and covariance matrix for the parameter estimates.

>   coxreg1$coefficients
        age         sex 
 0.01704533 -0.51321852 

> vcov(coxreg1)
             age          sex
age 8.506877e-05 8.510634e-05
sex 8.510634e-05 2.804217e-02

Now, if do a second regression with the stratified age variable, I don't get any coefficient estimates, variance or covariance.

coxreg2 <- coxph(SurvObj ~ strata(age) + sex, data =  lung)

> coxreg2$coefficients
     sex 
-0.64471 

> vcov(coxreg2)
          sex
sex 0.0449369

Thanks for the help!

1
As I read material about "age advancement periods" it appears that age (possibly represented as a functional other than the identity function) and a target exposure risks must be estimated jointly in a statistical model. Using strata prevents such an estimate, so your question is basically answered by saying "don't do that". The survival::coxph-function supports the use of a tt argument where age is represented as as a functional whose coefficient would be reported. We would need to see data to support a proper choice of the functional representation of age.IRTFM
Or if you need a worked example to follow, perhaps you can present the data used in this article in a form that R users might assimilate. This article appears to be extremely similar to the one cited above : sascommunity.org/seugi/SEUGI1994/…IRTFM
Nevermind. That second paper just has a macro with no demonstration of its use.IRTFM

1 Answers

2
votes

When you use a variable for stratification you don't get any coefficient estimate for it. Instead separate baseline hazards are estimated for the different age groups. The essence of a stratified cox regression is to fit a model that has a different baseline hazard in each stratum.