[R] CoxPH multivariate frailty model with coxph (survival)

David Winsemius dw|n@em|u@ @end|ng |rom comc@@t@net
Sun Jul 28 08:03:25 CEST 2019


On 7/19/19 10:19 AM, Denise b wrote:
>   Dear R users,
>
> I am interested in estimating the effects of a treatment on two
> time-to-event traits (on simulated data), accounting for the dependency
> between the two time-to-event outcomes.
>
> I precise that the events are NOT recurrent, NOT competitive, NOT ordered.
> The individuals are NOT related and can have 0, 1 or the 2 events (in any
> ordered).
>
> So, I specified a time-to-event model with one Cox PH hazard function for
> each outcome.
> The two hazard functions are linked by a common subject-specific frailty
> term (gamma distribution) to account for the dependency. The likelihood
> function of that model would include two risks sets (1 for eachoutcome)
> connected via the shared frailty term.
>
> To fit that model, I used the coxph function (survival R package, T.
> Thernaud):
> coxph( Surv(Time, Status) ~ treatment*Event_type + strata(Event_type) +
> frailty(ID), data=example)
If you have Event_type as a strata variable, it seems problematic that 
it be also interacting as a fixed effect.
> - where example is my dataset, with 2*N individuals (2 rows for each
> individual, corresponding to each time-to-event outcome)
> - Time = c(Time_outcome1, Time_outcome2)
How exactly do you expect the Surv-function to handle such a vector?
> - Status=c(Event_outcome1, Event_outcome2)

The help page for Surv() says:  "For multiple endpoint data the event 
variable will be a factor, whose first level is treated as censoring."

So it, too, would not be "expecting" a two-item vector. Seems that the 
multi-state formulation would make more sense.

> - Event_type=c(rep(0,length(Time_outcome1)),rep(1,length(Time_outcome2))


I'm reasonably sure 0 would be interpreted as a censored observation.

> - ID=c(ID,ID)
>
> So, the model implies different baseline hazard function for each outcome
> (argument strata) and estimate a treatment effect for each event type(
> treatment*Event_type).


I doubt it. I'm pretty sure there would be a conflation of effects and 
stratification.

>
> Although the model returns some estimates close to what I expected
> (simulation study), the problem is that most of the examples I found with
> this type of formulation are for competitive time-to-event models (as
> presented in Therneau's and Grambush's book "Modeling survival
> data"  (pages 240-260 and 175-185) and also in some info I found on


I cannot lay my hands on my copy of that text, but I'm fairly sure it 
never mixed strata(.) and fixed effects for a variable in the same model.


I suppose this is where I should admit  that I'm trained as an 
epidemiologist and not as a statistician, but I've done a fair amount of 
work with these models. Seems to me that your code are sufficiently out 
of the mainstream practice that you would at least want to create a 
simulated data-set and see if this results in agreement with assumptions.


-- 

David.

> internet).
>
> So, I am wondering if some of you have the same or different interpretation
> of mime.
> Otherwise do you have other functions to recommend me to fit the desired
> model, such as coxme...? I also checked the package " mets" which also
> describes several examples for competitive time-to-event traits, but not
> for NON competitive events.
>
> Thanks in advance for your help,
> Denise
>
> 	[[alternative HTML version deleted]]
>
> ______________________________________________
> R-help using r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list