I'm new proportional hazard ratio models and new-ish to R, so I suspect this is a basic question:
The scenario is modeling the speed of an effect through hazard ratios. People are joining an organization, and most are invited by someone else within the organization*. The speed measured is the time between when the invitation is made and the person joins the organization, called the
registration_interval. The way that seems evident to model this in R is like so:
analysis<-coxph(Surv(registration_interval) ~ Factor1 + Factor2 + Factor3 ...)
However, there's also the prospect that people are faster/slower to join the organization as the date of their invitation moves along (ex. people invited in 2012 might join faster than people joining in 2009), and this could interact with the various factors. What is a sensible way to incorporate this
*We only have data for those that do ultimately join the organization. We consider our model as simply modeling "joiners", and not right-censoring everyone whose invitation-registration intervals are infinitely long.
Edit for clarification: We know when people are invited, so on any given date there are only a certain number of people invited who could join. If everyone were invited all at once the proper model setup would just be:
analysis<-coxph(Surv(registration_interval) ~ date + Factor1 + Factor2 + Factor3 ...)
But since the
registration_interval is determined by two dates, there is some interaction between that and
date. The hazard function would, for example, look quite different if there is a span of time in which nobody is invited, versus a span of time in which thousands of people are invited. Perhaps this is all packaged within
Surv, and I'll look into it.
Edit regarding putting both
registration_interval or join time information in Surv: Nope. That appears to be a red herring.