I am having trouble interpreting the output from a Cox proportion hazard model with a spline term on a continuous exposure.

In the below example (pseudo-code from R) I see that there is a significant, non-linear relationship between circulating albumin levels and risk of death:


## create the survival object
surv.death <- Surv(age_at_death , dead_or_not)

## fit survival model
fit.death <- coxph(surv.death ~ pspline(albumin_baseline, df=4) + age_baseline + sex + smokes)

## get predicted values for fitted spline
predicted <- predict(fit.death , type = "terms" , se.fit = TRUE , terms = 1)

## plot lines
plot( albumin_baseline , exp(predicted$fit) , type="n" )
lines( sm.spline(albumin_baseline , exp(predicted$fit)) , col = "red" , lty = 1 )
lines( sm.spline(albumin_baseline , exp(predicted$fit + 1.96 * predicted$se)) , col = "orange" , lty = 2 )
lines( sm.spline(albumin_baseline , exp(predicted$fit - 1.96 * predicted$se)) , col = "orange" , lty = 2 )

Albumin and moratlity risk

I am struggling to interpret the Hazard Ratio plotted on the y-axis. I can see, of course, that the risk of death is much higher in the follow-up period if you have low albumin.

What I want to know is (for example) what the Hazard Ratio of 2 corresponding with an albumin value of 3.5g/dL is -- 2x the hazard compared to what? I am struggling with the conceptually because it is different to how one would compare a linear hazard ratio (i.e. increased hazard per unit of exposure).

Many thanks for all your inputs, and my apologies if there is a duplicate, I could not find the same question or an answer to my question in a similar topic!

  • 1
    $\begingroup$ See this related answer for a possible clarification: $\endgroup$
    – Shai
    Mar 30, 2016 at 14:07
  • $\begingroup$ @Luke Thx for your post. I tried your code on my data but I am getting the following error Error in xy.coords(x, y, xlabel, ylabel, log) : 'x' and 'y' lengths differ. I checked length(predicted$fit);length(data$Median_income) and found that there is difference of 1 i.e. 1692 and 1693 respectively. Any advice will be greatly appreciated. $\endgroup$ Aug 4, 2021 at 12:48

1 Answer 1


To get a nice interpretation, I would compare it with a meaningful baseline. In your example, the median Albumin score is about 4.25. So you could say something like "The estimated hazard for a subject with 3.5g/dL is about 2 / .9 = 2.22 times higher when compared with to a subject with 4.25g/dL (the median Albumin score in our data), if all other covariates are equal". The .9 was obtained from eyeballing the hazard ratio from the graph.

Does that sound reasonable?

  • $\begingroup$ Hi Cliff, thanks for your answer! This does sound reasonable, although I am conceptually a bit confused about what the actual values plotted represent. You have nicely explained how to interpret the difference between any two values of Albumin in terms of the difference in the mortality risk between them, however what does the absolute HR that the graph actually plots refer to? Again, thanks for your answer, I am just trying to fully understand what has been plotted/calculated by the Cox/spline model. Luke $\endgroup$
    – Luke
    May 22, 2015 at 14:53
  • $\begingroup$ Well, it's a little bit tricky. If you have a simple linear effect, the hazard ratio would be compared to the "baseline", i.e., subjects with all 0 covariates (although in this case, that is not a meaningful value anyways: you can't have 0 Albumin, right?). However, the basis expansion used in the spline will greatly complicate this: having x = 0 is NOT the same as having all the spline expansion covariates of x be 0. So with the spline expansion, what "baseline" even is is hard to know. $\endgroup$
    – Cliff AB
    May 22, 2015 at 16:41
  • $\begingroup$ Thanks for the comment Cliff. "... what the 'baseline' even is is hard to know" - this is what I was interested in; I mention in my question that 3.5g/dL of albumin has a HR of 2 - as you describe in your answer, this is clearly great than the HR for albumin levels of 4, but I do not understand where the 2 has come from. I had thought it was the hazard compared to that at the median/mean albumin level, but from the plot we can see that is not the case. If you can provide an explanation (short summary) that would be great, otherwise I can't really accept this as the answer! Cheers $\endgroup$
    – Luke
    May 25, 2015 at 19:06
  • 1
    $\begingroup$ In general, the hazard ratio is compared with "baseline"; i.e. a subject with all covariates = 0. However, you are looking a spline expansion of Albumin. This takes a single covariate and expands it into several covariates. The baseline, in this case, would be where all of these expanded covariates are equal to 0. But without knowing how the spline expanded Albumin, we don't know what raw value of Albumin corresponds with all of the expanded covariates being 0. $\endgroup$
    – Cliff AB
    May 25, 2015 at 19:21
  • $\begingroup$ I think I see - at least conceptually is not so much mathematically - many thanks for this additional explanation, it is much appreciated! $\endgroup$
    – Luke
    May 25, 2015 at 22:29

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.