options ls=80; data tenhave; infile 'tenhave.data'; input control y1 y2 y3 y4 y5 y6 y7 y8 y9 y10; output; run; data tenhave; set tenhave; rotate = 1 - control; y11=0; y12=0; y13=0; if y1=1 then y11=1; if y1=2 then y12=1; if y1=3 then y13=1; run; proc tabulate; class y1 y8 rotate; table y1*rotate; table y8*rotate; table y8*y1; run; proc logistic data=tenhave; model y1 = rotate; run; proc logistic data=tenhave; model y8 = rotate; run; proc logistic data=tenhave; class y1; model y8 = rotate y1; run; proc logistic data=tenhave; model y8 = rotate y11 y12 y13; run; proc logistic data=tenhave; class y1; model y8 = rotate y1 rotate*y1; run; proc logistic data=tenhave; model y8 = rotate y11 y12 y13 rotate*y11 rotate*y12 rotate*y13; run; data tenhave; set tenhave; fast1 = 0; if (y1 < 3) then fast1=1; fast8 = 0; if (y8 < 3) then fast8=1; run; proc tabulate; class fast1 fast8 rotate; table fast1*rotate; table fast8*rotate; table rotate*fast8*fast1; run; proc logistic data=tenhave; model fast8 = rotate fast1; run; proc logistic data=tenhave; model fast8 = rotate fast1 rotate*fast1; run;