Skip to main page content
U.S. flag

An official website of the United States government

Dot gov

The .gov means it’s official.
Federal government websites often end in .gov or .mil. Before sharing sensitive information, make sure you’re on a federal government site.

Https

The site is secure.
The https:// ensures that you are connecting to the official website and that any information you provide is encrypted and transmitted securely.

Access keys NCBI Homepage MyNCBI Homepage Main Content Main Navigation
Editorial
. 2018 Apr;6(7):121.
doi: 10.21037/atm.2018.02.12.

Time-varying covariates and coefficients in Cox regression models

Affiliations
Editorial

Time-varying covariates and coefficients in Cox regression models

Zhongheng Zhang et al. Ann Transl Med. 2018 Apr.

Abstract

Time-varying covariance occurs when a covariate changes over time during the follow-up period. Such variable can be analyzed with the Cox regression model to estimate its effect on survival time. For this it is essential to organize the data in a counting process style. In situations when the proportional hazards assumption of the Cox regression model does not hold, we say that the effect of the covariate is time-varying. The proportional hazards assumption can be tested by examining the residuals of the model. The rejection of the null hypothesis induces the use of time varying coefficient to describe the data. The time varying coefficient can be described with a step function or a parametric time function. This article aims to illustrate how to carry out statistical analyses in the presence of time-varying covariates or coefficients with R.

Keywords: Cox proportional hazards; Schoenfeld residuals; time dependent; time varying; time-to-event.

PubMed Disclaimer

Conflict of interest statement

Conflicts of Interest: The authors have no conflicts of interest to declare.

Figures

Figure 1
Figure 1
The effect of the covariate ph.karno on mortality outcome varies over time. The horizontal time axis is in “km” transformed scale, which is the default setting in the cox.zph() function. The dashed lines are lower and upper limits of confidence interval of the effect of ph.karno. It is noted that the effect of ph.karno is not time constant.
Figure 2
Figure 2
Time stratified effect of fixed baseline covariate on survival. Note that the effects of baseline covariate for different time windows are different, resulting in a series of hazard ratios.
Figure 3
Figure 3
A parametric time function is assigned to ph.karno. If the time axis is transformed by the function log(t+20), the effect is linear with the slope of 0.015 (red line).
Figure 4
Figure 4
Estimated cumulative coefficients with 95% pointwise confidence intervals for intercept, age, sex and ph.karno.

Similar articles

Cited by

References

    1. Zhang Z, Smischney NJ, Zhang H, et al. AME evidence series 001-The Society for Translational Medicine: clinical practice guidelines for diagnosis and early identification of sepsis in the hospital. J Thorac Dis 2016;8:2654-65. 10.21037/jtd.2016.08.03 - DOI - PMC - PubMed
    1. Pinsky PF, Zhu CS, Kramer BS. Lung cancer risk by years since quitting in 30+ pack year smokers. J Med Screen 2015;22:151-7. 10.1177/0969141315579119 - DOI - PubMed
    1. Collett D. Modelling Survival Data in Medical Research. 3rd ed. Boca Raton: Chapman and Hall/CRC, 2014.
    1. Adeleke KA, Abiodun AA, Ipinyomi RA. Semi-parametric non-proportional hazard model with time varying covariate. Womens Health Journal 2015;14:68-87.
    1. Kalbfleisch JD, Prentice RL. The Statistical Analysis of Failure Time Data. Hoboken, NJ, USA: John Wiley & Sons, Inc., 2002.

Publication types

LinkOut - more resources