data new;
input day live death;
cards;
Day_0 37 0
Day_6 36 1
Day_12 21 16
Day_18 8 29
Day_24 2 35
;
SO, in this case i want to estimate the survival rate between days and find statistical differences between them, and estimate, in the same way, in wich day occured the major mortality. THs objective here is to obtain a table like this:
Day | Total | Survival |
Day_0 | 37 | 100.00% |
Day_6 | 36 | 97.30% |
Day_12 | 21 | 56.76% |
Day_18 | 8 | 21.62% |
Day_24 | 2 | 5.41% |
Hello,
Producing the table shown is easy of course, but I have no idea on how to detect 'statistical differences between them'. The fact that this question was/is still un-answered makes me think your question is not entirely clear and/or your data are not suitable for this test.
Here's the program to produce the table:
data new;
input day $ live death;
cards;
Day_0 37 0
Day_6 36 1
Day_12 21 16
Day_18 8 29
Day_24 2 35
;
run;
proc means data=new /*nway*/ MAX noprint;
var live;
output out=MaxLive(drop=_TYPE_ _FREQ_) max=MaxLive;
run;
data want(drop=MaxLive);
if _N_=1 then set MaxLive;
set new;
Total=live+death;
Survival=live/MaxLive;
format Survival percent7.2;
run;
proc print; run;
/* end of program */
Cheers,
Koen
Hello,
Producing the table shown is easy of course, but I have no idea on how to detect 'statistical differences between them'. The fact that this question was/is still un-answered makes me think your question is not entirely clear and/or your data are not suitable for this test.
Here's the program to produce the table:
data new;
input day $ live death;
cards;
Day_0 37 0
Day_6 36 1
Day_12 21 16
Day_18 8 29
Day_24 2 35
;
run;
proc means data=new /*nway*/ MAX noprint;
var live;
output out=MaxLive(drop=_TYPE_ _FREQ_) max=MaxLive;
run;
data want(drop=MaxLive);
if _N_=1 then set MaxLive;
set new;
Total=live+death;
Survival=live/MaxLive;
format Survival percent7.2;
run;
proc print; run;
/* end of program */
Cheers,
Koen
Hello,
I see.
I do not know the answer.
I have little experience with survival models.
I know it's 'easy' to compare survival rates and survival curves across groups (with PROC LIFETEST f.e.), but how to compare survival rates at different time points within one group (within one curve), that I don't know (or do not know it by heart in any case).
I know how to compare proportions but that is not really applicable here (and for sure not with the data you present).
But thanks to my intervention, your question is again at the top of the list and so I hope experts on survival analysis will chime in and help you out. 😆
Cheers,
Koen
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
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.