1
$\begingroup$

I need an estimation of the baseline hazard in a semi-parametric survival random effect model. Initially, I tried to do it with splines and the frailypack package. But frailypack does not accept stratification on a covariate which is in interaction with the random effect (slope()).

library(frailtypack)
data(dataAdditive)
modAdd <- additivePenal(Surv(t1,t2,event)~cluster(group)+strata(var1)+
               var2+slope(var1),correlation=FALSE,data=dataAdditive,          
                n.knots=8,kappa=c(10000,10000))

I then tried to do it with generalized linear mixed-effects models with the family Poisson. This gives me an estimation of the piecewise baseline hazards. For this, I use the glmer function in the lme4package.

The problem is I need the estimation of the baseline hazard to be stratified on one covariate (which is in interaction with the random effect).

I have no clue of how to do it.

With the coxme function (coxme package), it is really simple. We just need to add a strataterm in the formula.

library(coxme)
library(frailtypack) #for the data
coxme(Surv(timeS,statusS)~strata(trt)+ trialID + (1|trialID/trt),data=gastadj)

Would anyone have a suggestion for me?

Thanks a lot !

$\endgroup$

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.