Hi,
I've generated a cox model, but I'm struggling to work out how to output
predictions based on the model I've made.
my.model<-coxph(Surv(duration,status) ~ gender + var1 + var2,
data=mydata)
My test data set looks something like this:
id,duration,gender,var1,var2
a, 65, m, 1, 3
b, 34, f, 1, 5
...
For each id, I would like to output a predicted duration based on the
cox model so that I can compare it with other models.
I've looked at the coxph documentation, but I can only see how to output
survival probabilities. I'm probably missing something obvious, but
trawling the mail archives has been fruitless, any suggestions?
Cheers,
George
|