I used the same data and sas code for survival analysis, in SAS EG 7.1 I got the 95% CI for the median survival with the upper limit as a determined number, but in SAS EG 8.3, the upper limit of the 95% CI is NE.
I am sure the SAS code and data has no change, and the only different is SAS version.
Has any one encountered such experience in proc lifetest using different SAS versions?
How to know which one is correct? Thank you in advance for any comments.
I found a post https://support.sas.com/kb/64/617.html
The upper confidence limit for a quartile qp in PROC LIFETEST is incorrect if these conditions are met:
Can you post code and data, so that the issue can be replicated?
It's possible that in your most recent version you have the Hot Fix applied as in the following Problem Note:
https://support.sas.com/kb/64/617.html
The Hot Fix described in the note is for Release SAS9.4 (TS1M6) = SAS/STAT 15.1. It is not uncommon after the Hot Fix is applied that some of the quartiles do not exist and that PROC LIFETEST reports them as missing.
The macro variable &sysvlong can be used in a %PUT statement to see what release you are running.
%put Version = & sysver (&sysvlong);
The results of the %put are in the log file.
Hello @fengyuwuzu,
I remember that we had to introduce the option CONFTYPE=LINEAR (of the SURVIVAL or, later, the PROC LIFETEST statement) to some of our survival analysis programs when we upgraded to one of the early SAS 9 releases. Otherwise the confidence intervals for quartiles of the survival times would have changed (compared to earlier SAS versions, especially SAS 8.2 [not to be confused with SAS EG 8.2]). The reason was that the default was changed to CONFTYPE=LOGLOG (and the CONFTYPE= option did not even exist in SAS 8.x). This is mentioned in Overview: LIFETEST Procedure (next to last paragraph) and explained in detail in the PharmaSUG 2014 paper "Our Survival Confidence Intervals are not the Same!"
Here is an example where the existence of the upper confidence limit of the third quartile depends on the CONFTYPE= option (using SAS 9.4M5, SAS/STAT 14.3):
ods select quartiles; proc lifetest data=sashelp.BMT(firstobs=99) conftype=linear; time T * Status(0); run; ods select quartiles; proc lifetest data=sashelp.BMT(firstobs=99) conftype=loglog; time T * Status(0); run;
With the current default CONFTYPE=LOGLOG the upper CL is missing, whereas with the old default (corresponding to) CONFTYPE=LINEAR it exists.
Below is my code (and I did use conftype=loglog)
:
ods output QUARTILES = out_Quarts (where = (PERCENT = 50) keep = estimate group percent LOWERLIMIT UPPERLIMIT);
proc lifetest data=mydata alpha=0.05 conftype=loglog;
time aval*cnsr(0);
strata group;
run;
By the way , I tried my data in R, using survival package, and I also got NA for the upper limit of the 95% CI.
Thanks for posting your code. So, with identical input data and code, in particular using conftype=loglog, the two SAS EG versions produce different results (and the difference is not explained by that Problem Note 64617)?
In this case I would
Thank you. My data meets the first condition of 64617 note, but not the second condition. I am not sure if the data need to meet both condition to apply this explanation. I guess it is due to the 64617 hot fix in new SAS/STAT 15.2.
The upper confidence limit for a quartile qp in PROC LIFETEST is incorrect if these conditions are met:
@fengyuwuzu wrote:
I am not sure if the data need to meet both condition to apply this explanation.
The upper confidence limit for a quartile qp in PROC LIFETEST is incorrect if these conditions are met:
- an event is observed at the largest time
- the largest event time is also the first time the survival estimate drops below (1-p) for the 100pth percentile point, given the pointwise upper bounds for the survival estimate have not dropped below (1-p) at previous times
My understanding is that both "these conditions" must be met. (The first criterion alone would also seem to me too weak a condition for SAS to produce "incorrect" results from version 9.2 until 9.4 TS1M6, i.e., over many years.) Moreover, I suspect that the two conditions are only necessary conditions for the error to occur: If I'm not mistaken, the almost trivial example of just two survival times t1=1, t2=2, both uncensored, meets both conditions for p=0.75 and yet the upper confidence limit (=2) for that quartile, as obtained with SAS 9.4TS1M5 (SAS/STAT 14.3) using conftype=linear, matches what I get from the formula in the documentation.
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.