# Which statistical test to use when some residuals are normal and some are non-normal?

I have some response data from an experiment which uses appraisal methods to assign scores based on various attributes. The scores are awarded (in part) from visual observations of biological condition, i.e. the scales are ordinal, and also from quantitative measurements. The results of the visual observations and the mensuration are combined and the final response data is continuous. I have four different appraisal methods which all work in this way, using slightly different criteria and scoring.

The null hypothesis which I am testing is that my treatment has no effect on the score. When I run an ANOVA or linear model and examine the residuals, some are returned as normally distributed and some are not. I intend to publish the paper.

How do I deal with this in my analysis? Is it acceptable to run two types of test (ANOVA and a non-parametric test). I am using R (v 3.4.4) for my analyses.

Here is an example of one response using one way ANOVA.

The SW test shows non-normal residuals

Shapiro-Wilk normality test

data:  residuals(aov_BURNLEY)
W = 0.8724, p-value = 8.776e-08


Another example using one way ANOVA.

The SW test shows normally distributed residuals

Shapiro-Wilk normality test

data:  residuals(aov_CTLA)
W = 0.98722, p-value = 0.4526


And another example using one way ANOVA.

The SW test shows non-normally distributed residuals

Shapiro-Wilk normality test

data:  residuals(aov_STEM)
W = 0.37409, p-value < 2.2e-16


If you know right off the bat that your data is non-normal you should first look to see if it follows some other distribution. You can use the glm function which allows you to model distributions like binomial and Poisson. Or your data may be multinomial in which case you can use multinom or clm. If you want to go down the non-parametric path you should read up on some statistical computation work like Monte Carlo simulations and Bootstrap sampling.
Anyway the first plot you looked at looks like a gamma distribution which you can use glm(response ~ model, family = Gamma(link = "log"))
• I would suggest a log transformation $log(Y + min(Y) + .01)$ that way you transform the data to positive values, shift the distribution to the right some and hopefully achieve near normality. Also remember to do a back transformation when interpreting results. – Rex Feb 9 at 2:22