Hi all,

I have some questions about the predicted HR in coxph function including
psline covariate.

If just fitting covariate as linear form, by default, the reference value
for each of predictions type (linear predictor, risk and terms) is the mean
covariate within strata.

If the psline is specified for the covariate, what's the reference value
for the predictions?
I did some test code below:
###
par(mfrow = c(1,3))
test = coxph(Surv(time, status) ~ age, cancer)
test2 = coxph(Surv(time, status) ~ pspline(age, df=2), cancer)
test3 = coxph(Surv(time, status) ~ pspline(age, df=5), cancer)
pptest3=predict(test3, type="lp")
pptest2= predict(test2, type="lp")
pptest = predict(test, type="lp")
plot(cancer$age, exp(pptest))
abline(v=mean(cancer$age))
abline(h=1)
plot(cancer$age, exp(pptest2))
abline(v=mean(cancer$age))
abline(h=1)
plot(cancer$age, exp(pptest3))
abline(v=mean(cancer$age))
abline(h=1)

In the first model, age is just fitted as linear, and in the plot, when HR
=1 when age equals to the mean of age. However, it's not the case when age
is fitted as using psline.

So what are the reference value of age when psline is used? Any help or
idea will be very much appreciated!

Best,
Carrie--

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to