BookmarkSubscribeRSS Feed
mili
Fluorite | Level 6

Hello,

 

I have the following code:

 

proc phreg data = cstat concordance  = harrell (se); 

  model survival * censored (1) = age sex;

run;

 

I would like to output in a new dataset the results of this procedure as to have a column for: estimate, standard error, concordance, discordance, tied in predictor and tied in time.

 

Basically, I'd like to be able to create a new dataset with the outcome of the "concorance = harrell (se)" as we can get the maximum likelihood estimates of model parameters by running:

 

proc phreg data = cstat ; 

  class sex (ref = '1');

  model survival * censored (1) = age sex;

  ods output parameterestimates = parms_cstast;

run;

 

Thank you very much!!

 

run;

3 REPLIES 3
Astounding
PROC Star

I can't give you the answer, but I can set you on the road toward finding it.  Add this statement before the PROC:

 

ods trace on;

 

When you run the PROC, it will give you the names of all the ODS data sets that are available.  You might have to inspect them to find which one contains the information you are looking for, and then the proper data set to the ODS OUTPUT statement.

mili
Fluorite | Level 6
Thank you for the very prompt reply! Thanks to you, I found it. It's
"concordance" (I should have thought of it!!). So it is

proc phreg data = cstat ;
class sex (ref = '1');
model survival * censored (1) = age sex;
ods output *concordance* = parms_cstast;
run;

Thank you SO MUCH!!
Milli

Reeza
Super User

For future reference you can also find the relevant table names in the documentation under ODS Table Names for each procedure.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 982 views
  • 2 likes
  • 3 in conversation