* SAS code for Aquatic survival data from Table 8.3; options linesize=70; data asg; input stage $ u y n @@; p=y/n; cards; a 0 23 25 a 0 23 25 I other data omitted for space considerations I n 84 0 20 n 84 1 20 proc standard data=asg mean=0 out=ag2; var u; proc genmod data=ag2; class stage; model y/n = u stage / dist=b link=logit type1; contrast 'A vs. C' stage 1 -1 0 ; contrast 'A vs. N' stage 1 0 -1 ; contrast 'C vs. N' stage 0 1 -1 ; run;