I have a data set that I'm trying to model using survival analysis, specifically cox proportional hazard models. The data has patient IDs and several attributes about the patients (including time till failure). Due to the nature of the data, a patient could fail and then fail again later several times. This means that some of the patients are repeated in the data due to multiple failures. However, patients aren't all repeated and when they are, they aren't all repeated the same number of times.
My question is: how should this be handled in cox proportional hazard modeling?
Should each instance be treated as independent (I don't think that would make too much sense)?
Should the patient data be aggregated in some way so that each patient is being included once in the model while still utilizing his/her data from the multiple failures?
Thanks!