O'Reilly logo

Survival Analysis Using SAS®: A Practical Guide by Paul D. Allison

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Generating Predictions and Hazard Functions

After fitting a model with PROC LIFEREG, it’s sometimes desirable to generate predicted survival times for the observations in the data set. If you want a single point estimate for each individual, the predicted median survival time is probably the best. You can get this easily with the OUTPUT statement, as shown in the following example:

proc lifereg data=recid;
   model week*arrest(0)=fin age race wexp mar paro prio
         / dist=weibull;
   output out=a p=median std=s;
run;
proc print data=a;
   var week arrest _prob_ median s;
run;

The P= keyword in the OUTPUT statement requests percentiles. By default, PROC LIFEREG calculates the 50th percentile, that is, the median. (The word median in the OUTPUT statement is ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required