I aim at estimating a competing risks / multistate model with frailties with the coxme
R-package and the survival
package. I think that this is possible to do in the surivial
package with the coxph
function:
# competing risks model
survival::coxph(Surv(time, type) ~ X + frailty(ID), id = ID, data = data)
# where type is a factor consisting of target states
# multistate model
survival::coxph(Surv(StartTime, EndTime, toState) ~ X, data = data, id = ID, state = fromState)
However, for the multistate model, it is not possible to add the frailty(ID)
part of the formula. Why?
And: how would I go about to model competing risks and multistate models with the coxme
package? The surivial
package documentation (p. 48) suggests that the coxme
package superseds the method of adding a frailty(ID)
to the coxph
term. Hence, it would be better to model frailties with the coxme
package. But there is no documentation for the coxme
package for modeling competing risks or multi-state models.
frailty(ID)
, whereascluster(ID)
runs just fine. (Though I am not confident thatcluster(ID)
is correct!) $\endgroup$