Hi all, I have a question about checking the residual normality for binomial data that is being analyzed with PROC GLIMMIX. I have 291 subjects with treatment and pen being the classes. The analysis is to determine if there was a statistically significant difference between treatments for subjects that graded AAA vs ones that didn't, therefore I've organized my data as a binomial distribution; if they graded AAA (1) vs if they didn't (0). Below is the code I am using to analyze the data. proc glimmix; class trt pen; model aaa = trt / d=binomial link=log; output out=resid pred=predicted residual=residual; lsmeans trt / diff lines ilink; contrast 'CTL vs Treatments' trt 4 -1 -1 -1 -1; contrast 'CTL vs Low Straw' trt 2 0 0 -1 -1; contrast 'CTL vs High Straw' trt 2 -1 -1 0 0; contrast 'Low Straw vs High Straw' trt 0 1 1 -1 -1; contrast 'Canola vs Flax' trt 0 1 -1 1 -1; run; However, I'm running into issues when I try to analyze the residuals. Primarily because in our stats class they didn't specify how to analyze residuals for binomial data and what the assumptions are for models that analyze binomial data. Are the residuals still supposed to be normally distributed? If not, how would you go about analyzing the residuals, would you still use PROC UNIVARIATE? I tried the following code (which is similar to the code I use to check residuals for my other linear regression model): proc univariate plot data=resid; var residual; ods select Extremeobs plots; run; proc univariate data=resid normal plot; var residual; run; However, my Shapiro-Wilk value comes out to <0.0001 and my residual plots come out looking not normal at all. I've attached my SAS syntax as a file to this. Any help about this would be appreciated. Thanks
... View more