Hello,
Were you able to resolve this? I am looking to create a multilevel model with 2 clusters (ID and center) with recurrent events. The PROC PHREG statement only seems to allow for one random effect in the RANDOM statment. When I write the RANDOM statement twice for the 2 variables, it doesn't appear to work. I took a look into PROC SURVEYPHREG, which allows you to have more than one RANDOM effect, but I'm not sure how to adjust of the recurrent events.
proc phreg data=final_survival_export covs(aggregate) covm;
class pt_id prev_enteral_feed (ref='0') /*need this to specify for random effect*/;
model (visit0 visit1)*rs(0)= prev_enteral_feed/rl ties=efron; /* RL= 95% (default alpha level) confidence limits for the hazard ratios.*/
random pt_id; *shared frailty;
id pt_id; /*not sure if this ID step is needed*/
run;
This is what I had for the 1 random effect model that accoounts for recurrent events, however I need 2 random effects.
... View more