Survival analysis with external non-competing events I'm new to survival analysis and struggling to find the best approach to my problem:
Assume that we want to model the time to the death event $X$ given some prior subject data.
I'm aware that survival analysis can be used for this, but what if there are other events ${Y_1, Y_2, Y_3, ...}$ that might influence the distribution for $X$? These events are not competing with $X$, i.e. the process will continue even if one of them occurs, it solely increases or decreases the hazard.
Supposedly, the easiest way to solve this is by using a Bayesian framework. 
If possible, implementation tips for Python would be particularly helpful.
 A: A competing event is formally any event that "curtails the incidence" of a particular outcome. If an event is non-competing, it is a censoring event. For instance, suppose a new intervention is designed to reduce heart-failure hospitalizations. It's so beneficial that the sickest people who would otherwise die of heart disease, live longer to be hospitalized for heart-failures more often. If CV-death is considered a censoring event, we say the intervention increases HF-hospitalizations. If CV-death is considered a competing event, we say that it decreases HF-hospitalizations.
The idea of a stochastic, time-varying covariate is a distinct concept altogether. When some event (call it $Z$, not $Y$ here) affects the value of $X$ and causes time-dependent confounding, one must input both $X$ and $Z$ as time varying covariates. To do this, at any point when the value of $Z$ or $X$ changes at some time $t$, censor the subject at time $t$ with their old covariate values and re-enter them in the risk set at time $t$ with the new covariate values.
This method was described by Hernan in a 2006 paper and was shown, for these time-to-event data, to have similar properties to M-estimation for binary events to handle confounding by indication in longitudinal studies.
A: It would seem logical to take an approach, where you either take the other events as given time-varying covariates, or you do a joint model for death and these events (e.g. joint frailty models,  there's a lot of papers on this recently). The first approach is sensible if the events have nothing to do with the patient (e.g. political turmoil in their country), or if you want to simply be able to take them into account without being able to predict taking then into account. The second approach can predict taking then into account and is also an option if want to do to study e.g. the effect of an intervention that may effect both death and these other events. 
