Penalized Spline Cox Regression
Penalized spline Cox regression lets a continuous covariate affect the log hazard through a smooth curve instead of a straight line. The curve is built from many B-spline pieces whose coefficients are penalized for roughness, so the effective degrees of freedom, set directly or chosen by AIC, control how flexible the curve can be. Other covariates enter linearly as in an ordinary Cox model.
벌점 스플라인 Cox 회귀는 연속형 공변량이 로그위험에 직선이 아니라 매끄러운 곡선으로 영향을 주도록 합니다. 곡선은 여러 B-스플라인 조각으로 만들고 계수의 거칠기에 벌점을 주므로, 직접 정하거나 AIC로 고른 유효자유도가 곡선의 유연성을 조절합니다. 다른 공변량은 일반 Cox 모형처럼 선형으로 들어갑니다.
Is the effect of a continuous covariate on the hazard nonlinear, and what does the hazard ratio curve look like?
연속형 공변량이 위험에 미치는 효과는 비선형이며, 위험비 곡선은 어떤 모양입니까?
The method returns the estimated log hazard ratio curve relative to the median with pointwise standard errors, the effective degrees of freedom and smoothing parameter, a Wald test of the spline term, a likelihood-ratio test of nonlinearity against a linear term, and the linear coefficients of other covariates.
When to use Penalized Spline Cox Regression
- A continuous covariate may have a threshold, U-shaped or saturating effect on the hazard.
- You want to check the linearity assumption of a Cox model.
- You prefer a data-driven curve to arbitrary categories.
When to use something else
- The baseline hazard rather than a covariate effect should be smooth: use Flexible Parametric Survival Model (Royston-Parmar)
- All effects are linear: use Cox Proportional Hazards Model
Assumptions and requirements
- Proportional hazards
- Independent censoring
- The effective degrees of freedom are set or chosen before interpretation
What the analysis reports
- Log hazard ratio curve with pointwise SEs
- Effective df and smoothing parameter
- Wald test and nonlinearity test
- Linear coefficients
How to report it
The penalized spline for [value] used [value] effective df; the test of nonlinearity gave chi2 = [value] on [value] df, p = [value].
Related methods
- Cox Proportional Hazards Model
- Flexible Parametric Survival Model (Royston-Parmar)
- Natural Cubic Spline Regression
- Cox Model Residual Diagnostics (Cox-Snell, Martingale, Deviance, Score)
How this method is validated
이 방법의 검증 근거
- Independent computation. 2 reference tests compare the results with SciPy, lifelines and direct computations (formulas, enumeration or simulation) at a stated tolerance of 1e-4.
독립 계산. SciPy·lifelines·직접 계산(식·열거·모의실험) 대조 참조 시험 2건 통과(허용오차 1e-4).
Tolerances are relative differences (absolute differences for values near zero). R comparisons and reference tests are re-run before each release of the analysis engine.
허용오차는 상대 차이입니다(0 근처 값은 절대 차이). R 대조와 참조 시험은 분석 엔진을 배포할 때마다 다시 돌립니다.
Run Penalized Spline Cox Regression on Quorant
- Data you need
- a table (CSV or Excel) with a time variable, an event indicator and predictor (feature) columns
- Price
- 400 credits for one analysis up to 10,000 rows (complexity level 3); larger or wider data costs more. Optional methodologist review: 1800 credits.
- Checking
- Compared with independent computations
- Before you pay
- A free pre-analysis diagnosis checks your data and gives an exact quote; nothing is deducted until you approve it.