/* A non-catastrophic (program still runs) typo was found in the code (Thanks Beth) and fixed. Confidence limits for contrasts are coded differently for PROC MIXED and PROC GLM, as in the following example: proc glm; class ht spacing block; model y=ht|spacing block/clparm; estimate "hi - lo" spacing -1 1; run; proc mixed; class ht spacing block; model y=ht|spacing; random block; estimate "hi - lo" spacing -1 1; run; */ options ls=75; data one; input ht $ spacing block y; if ht=0 then height="low "; else if ht=0 then height="high"; cards; 0 0.25 1 30.7 0 0.25 2 24.7 0 0.25 3 16.9 0 0.50 1 22.7 0 0.50 2 15.0 0 0.50 3 13.6 0 1.00 1 23.0 0 1.00 2 17.1 0 1.00 3 15.2 1 0.25 1 28.4 1 0.25 2 19.6 1 0.25 3 16.2 1 0.50 1 20.1 1 0.50 2 16.8 1 0.50 3 15.1 1 1.00 1 18.4 1 1.00 2 13.9 1 1.00 3 14.3 ; run; *proc mixed method=type3; proc glm; class ht spacing block; model y=ht|spacing block; random block; estimate "high - low" ht -1 1/cl; *lsmeans spacing/diffs adj=tukey; /* with PROC MIXED */ means spacing/tukey; run;