Open JamesPHoughton opened 5 years ago
Hi @JamesPHoughton
The only thing I can suggest is to use the cluster_col
arg (similar to the cluster
in R's survival). https://lifelines.readthedocs.io/en/latest/Examples.html#correlations-between-subjects-in-a-cox-model
Thanks! That's probably enough...
Sorry to reopen - is there a way to pass a cluster_col to the CoxTimeVaryingFitter
? I see that it's not implemented in: https://github.com/CamDavidsonPilon/lifelines/blob/master/lifelines/fitters/cox_time_varying_fitter.py#L92
Would it be an analogous operation to the implementation in https://github.com/CamDavidsonPilon/lifelines/blob/master/lifelines/fitters/coxph_fitter.py#L1208 ?
If you think the method could be ported there easily, I'd be happy to take a crack at it if you'd review for me?
Hi @JamesPHoughton, it's not implemented yet, and IIRC, it's trickier than the non-time-varying model. Sorry if you lost some time here!
hello,
I used the the cluster_col argument with cox regression and works pretty well, was wondering if there is a way to include a term related with the clustered_col. Something like a random intercept and a random slope
greetings
@ioannis12 unfortunately not! Maybe someday
Let's say that some samples are grouped (patients in a hospital, etc.) and that these groupings induce correlations between the samples.
If I'm interested in understanding the effect of treatment using a CoxPH model (or more generally a time-varying CoxPH model), is there a straightforward way for me to include a random effect for the group?