options nocenter ls=78; goptions colors=(none); data new; input varty pest resp @@; cards; 1 1 49 1 1 39 1 2 50 1 2 55 1 3 43 1 3 38 1 4 85 1 4 73 2 1 55 2 1 41 2 2 67 2 2 58 2 3 53 2 3 42 2 4 53 2 4 48 3 1 66 3 1 68 3 2 85 3 2 92 3 3 69 3 3 62 3 4 85 3 4 99 ; proc sort; by pest varty; proc means noprint; var resp; by pest varty; output out=new1 mean=mn; symbol1 v=circle i=join; symbol2 v=square i=join; symbol3 v=triangle i=join; proc gplot; plot mn*pest=varty; proc glm data=new; class varty pest; model resp = varty|pest; lsmeans varty|pest / slice=varty adjust=tukey stderr tdiff; output out=new1 r=res p=pred; symbol1 v=circle i=none; proc gplot; plot res*pred; run;