smoothHR: an R package for pointwise nonparametric estimation of hazard ratio curves of continuous predictors.
The Cox proportional hazards regression model has become the traditional choice for modeling survival data in medical studies. To introduce flexibility into the Cox model, several smoothing methods may be applied, and approaches based on splines are the most frequently considered in this context. To better understand the effects that each continuous covariate has on the outcome, results can be expressed in terms of splines-based hazard ratio (HR) curves, taking a specific covariate value as reference. Despite the potential advantages of using spline smoothing methods in survival analysis, there is currently no analytical method in the R software to choose the optimal degrees of freedom in multivariable Cox models (with two or more nonlinear covariate effects). This paper describes an R package, called smoothHR, that allows the computation of pointwise estimates of the HRs--and their corresponding confidence limits--of continuous predictors introduced nonlinearly. In addition the package provides functions for choosing automatically the degrees of freedom in multivariable Cox models. The package is available from the R homepage. We illustrate the use of the key functions of the smoothHR package using data from a study on breast cancer and data on acute coronary syndrome, from Galicia, Spain.
Center of Mathematics, University of Minho, Campus de Azurem, 4800-058 Guimarães, Portugal.
Luís
L
Meira-Machado
Department of Statistics and O.R., University of Santiago de Compostela, 15782 Santiago de Compostela, Spain.
Carmen
C
Cadarso-Suárez
Clinical Epidemiology Unit, University Clinical Hospital of Santiago de Compostela, 15782 Santiago de Compostela, Spain.
Francisco
F
Gude
Center of Mathematics, University of Minho, Campus de Azurem, 4800-058 Guimarães, Portugal.
Artur
A
Araújo
D054058:Acute Coronary Syndrome / Q000175:diagnosis* / Q000453:epidemiology; D000465:Algorithms; D001943:Breast Neoplasms / Q000175:diagnosis* / Q000453:epidemiology; D016208:Databases, Factual; D005260:Female; D006801:Humans; D015999:Multivariate Analysis; D011379:Prognosis; D016016:Proportional Hazards Models; D012044:Regression Analysis; D012984:Software; D013030:Spain