This is the code
ods output Quartiles= median_ci(where=(percent=50));
proc lifetest data=test;
time duration*censor(1);
strata group;
run;
It runs, but in results for quartile estimates it only shows complete data (point estimate, 95 CI) for the percent 25. There is no point estimate for 50 or 75. For this percents, it only shows the lower CI. Is this something to do with the data? Should I calculate the median and CI with another proc? The median and CI are to describe survival data. Any help is appreciated.
It appears that to generate the quartiles the METHOD= on the Proc statement should be one of PL B or FH from the online help Details tab under ODS Table Names . The default is KM when not stated.
Check the definition of the CENSOR variable in your data? Is it possible that you should be using CENSOR(0) instead of CENSOR(1) on the TIME statement? If you accidentally switch the 0/1 value, you can get the situation that you describe.
Thanks for your response. I defined censor=1 to subjects who survived and did not show progression of disease. If I change censor (0) in the code (below) it gives all quartiles. Is this switch ok? I am not sure this is right.
ods output Quartiles= median_ci(where=(percent=50));
proc lifetest data=test;
time duration*censor(0);
strata group;
run;
Hello @ANKH1,
Missing quartile point estimates and confidence limits are quite common if the Kaplan-Meier curve and related curves for the confidence limits don't drop far enough -- a data-dependent issue: see explanations in Re: Why did I get confidence intervals without a estimate? (and the PROC LIFETEST documentation page linked there) and Re: Kaplan Meier stats.
Also, there was a long standing bug impacting some of those calculations of PROC LIFETEST, which has been fixed only in SAS 9.4M7 (and later releases): see Problem Note 64617: The LIFETEST procedure produces incorrect upper confidence limits for the quarti....
Thank you!
Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!
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.
Ready to level-up your skills? Choose your own adventure.