0
$\begingroup$

I have a survival/duration dataset with competing risks. The start years for the durations vary and range from 2010 to 2019. Each individual may only start once, e.g. during 2010, and therefore cannot be in the risk groups of the other years. Follow-up ends after 200 days, i.e. the individuals are treated as censored, if they did not transition within 200 days after they became at risk. They are exposed to 3 competing risks, e.g. A, B and C. Using this data, I can calculate cumulative incidence functions (CIF).

If I want to test for differences between the CIF's of one risk, say risk B, but for different years, then there are multiple options. Gray's K-sample test is the most frequently used, but I could also use the Log-rank test or a test invented by Pepe and Mori (1993).

Pairwise testing, whether or not the CIF's of risk B in the pairs of years (2010, 2011), (2011, 2012), (2012, 2013) etc. differ significantly from each other, always yields significant results. Testing all years together using Gray's K-sample test also always results in significant results. When plotting the CIF's of risk B, the distances between the lines for the adjacent years, e.g. 2010 and 2011 compared to 2011 and 2012, appear fairly similar in their size and direction. This suggests, that there may be a trend, which leads to fewer and fewer observations of risk B over time.

Now to my question: Is there a way to test whether or not the difference between the CIF's of risk B of the pair of years (2010, 2011) is the same as the difference between the CIF's of risk B of the pair of years (2011, 2012)?

Naturally, searching for "testing for difference of differences" yielded rather unrelated results. I thought about some other approaches:

  1. I could calculate the difference between two CIF's and compare this to the difference between two other CIF's, but I don't which test to apply.
  2. Applying a competing risk regression with dummy variables for each year, with 2009 as the reference year, and then testing for Beta_2011 - Beta_2012 = Beta_2012 - Beta_2013 and analogously for the other pairs of years also crossed my mind, but I genuinely have no clue how the test statistic would have to be calculated.
  3. Adding a trend trend variable to the regression with the year dummy variables. If none of the year dummies is significant, and only the trend variable matters, this would indicate, that the differences between the years are not due to the years differing from each other per sé, but due to a strong trend.

Any input will be appreciated!

$\endgroup$
2
  • $\begingroup$ Do you have actual calendar start dates for each individual, or only the year during which each individual started? $\endgroup$
    – EdM
    Commented May 14, 2022 at 17:39
  • $\begingroup$ Each individual has a known calendar start date, e.g. 25 Feb. 2012, such that the durations can be calculated accurately. The durations range from 1 to 200 days. $\endgroup$
    – kEngelaar
    Commented May 15, 2022 at 16:29

1 Answer 1

0
$\begingroup$

This situation would seem to be handled nicely by including the calendar date of study entry as a covariate, modeled flexibly with regression splines. That way you aren't limited to a linear association of entry date with outcomes or to arbitrary binning into years of entry. In principle, with a Cox or other model of the competing risks, you could then test differences in predicted hazards for any desired combinations of entry dates (or other covariates).

The competing risks vignette of the R survival package covers the issues in Section 3. You will have to make some decisions based on your understanding of the subject matter. In particular: do you want the same functional form of association with study entry date for all risks, or do you want to allow that to differ among the risks?

$\endgroup$
2
  • $\begingroup$ This is an interesting approach. My initial thought was using a trend variable for the years, but using the calendar day would of course be much more accurate. Regression splines appear to be implementable easily using pspline(). Just to be clear: predict() would deliver the predicted hazards and by predicting for different values of the explanatory variables, i.e. calendar days. Which command should I use then to test for differences in the predictions? The package index of "survival" lists several tests, but none of them appears appropriate. $\endgroup$
    – kEngelaar
    Commented May 18, 2022 at 14:21
  • $\begingroup$ @kEngelaar you can use survfit() to get full survival curves for specified covariate values. I believe that the mstate package has helper tools for that sort of thing. See, for example, its msfit() function. With the variances and covariances of estimates, you can use the formula for the variance of a sum of correlated variables to make any comparisons that you wish. As these are asymptotic estimates, you use z-tests that assume they follow a normal distribution. $\endgroup$
    – EdM
    Commented May 18, 2022 at 16:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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