2
$\begingroup$

My data set looks like this

ID   Weak_year  Strong_year  Covariate1 Covariate2 ...
1    1966       NA           0.35       0.29
1    NA         1987         0.97       1.20
2    NA         1970         0.76       0.90         
3    1975       NA           1.4        3.2
4    ...
...

So each object can produce either a weak reaction, a strong reaction, or a weak and then strong reaction. Weak_year is the year a weak reaction happens, strong_year is the year a strong reaction happens. The covariates are independent variables; their values are the values for the year that the reaction events happened.

The start of the study is 1965 and the censoring time is 1990. Some observations are right-censored.

I'm familiar with survival analysis of binary outcomes (event or non-event), but I'm not sure how to model the time to event when there are three outcome levels of different strengths like these. What are some options to think about? It would be especially useful if these options can be implemented in R (that's what I'm using).

$\endgroup$
2
$\begingroup$

My guess is that you have what is called a multi-state model, with 4 states: no reaction (state 1), from which transitions are possible to weak / strong reactions (states 2 and 3) and from either of them a transition is possible to "weak & strong reaction" (state 4). Then you would analyze the transition intensities between these states (which are, in fact, hazards).

This is a generalization of competing risks models (which is what you would have if there would be no state 4 as I described above).

Multistate models are not difficult, at least not if you employ a number of assumptions, such as the transitions being Markov. There is a huge amount of literature on the topic, and I am sure you can find a lot online, including books on how to use these in R. To implement such a thing in R is not necessarily difficult, but it requires a bit of fiddling and putting the data in a nice form. For simple ones, you can actually use the survival package (there is a vignette on the topic). Other two packages specialized for multistate models are mstate and msm. Both come with tutorials that you can find online.

$\endgroup$
  • $\begingroup$ This sounds exactly like what I'm looking for! Follow-up question: page 25 of the msm package documentation says that "the only transition on which the effect of sex is significant at the 5% level is the 1-2 transition". According to wikipedia "a statistically significant hazard ratios cannot include one in their confidence intervals". However does this necessarily mean that if the confidence interval doesn't include one then the corresponding hazard ratio is significant at the 5% level? $\endgroup$ – user90593 Jun 25 '16 at 16:11
  • 1
    $\begingroup$ I don't know about which documentation you refer to. The quote means that sex is allowed to have a different impact in different transitions, and that the hazard ratio of sex for the 1-2 transition is the only one significantly different from 1. And yes, this is equivalent to saying that the 95% confidence interval does not include 1. $\endgroup$ – Theodor Jun 25 '16 at 16:22
  • $\begingroup$ Could you explain how msm deals with right-censored observations? The documentation cran.r-project.org/web/packages/msm/vignettes/msm-manual.pdf doesn't seem to explain that very clearly. $\endgroup$ – user90593 Jun 25 '16 at 17:37
  • $\begingroup$ It looks pretty clear to me, but I don't have experience with this package. The difference between multistate models and regular survival analysis is that now a possible transition that did not happen (for example, an individual goes 1-2, but not 2-4), then the transition 2-4 is taken as censored. $\endgroup$ – Theodor Jun 27 '16 at 7:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.