4
$\begingroup$

I have four linear mixed effect models of similar structure:

model1 <- lmer(index1 ~ biophony + anthrophony + (1|Site), data=df, REML=F) 
model2 <- lmer(index2 ~ biophony + anthrophony + (1|Site), data=df, REML=F) 
model3 <- lmer(index3 ~ biophony + anthrophony + (1|Site), data=df, REML=F) 
model4 <- lmer(index4 ~ biophony + anthrophony + (1|Site), data=df, REML=F) 

These models are testing the relationship between biophony (sounds generated by biodiversity) and anthrophony (sounds generated by humans) with four different indices for bioacoustic diversity, with Site as a random effect.

Index 1 is a sum of positive values. Index 2 is a sum of proportions. Index 3 is the area under the curve on a plot of frequency (Hz) against decibels (dB). Index 4 is a ratio of power in two frequency bins. Therefore indices 1-3 can only be positive. Index 4 is bounded by -1 to +1.

Using the following code to generate normal QQ-plots of the residuals:

qqnorm(residuals(model1))
abline(0,1)

I have found that the residuals of the models look very non-normal (see plots below). The first plot appears to be heavy-tailed. The rest I do not know what distribution the plots indicate (I can't find any examples online of similar plots).

Normal Q-Q Plots of Models 1-4

I have already tried log transforming the indices data but this hasn't improved the distribution of the data. I have tried using the boxcox function to find an appropriate power transformation as described here, but again this did not improve the distribution of the residuals.

My questions are:

  1. Should I transform the data? If so can you recommend appropriate transformations?
  2. If a transformation isn't appropriate, should I use generalised linear mixed models to analyse these data? Could you recommend what family and link functions would be appropriate for a glmer analysis of data of these distributions?

I have attached histograms of the marginal distributions of the indices data for more information:

Histograms of indices 1-4

$\endgroup$
  • $\begingroup$ Can you say a little about how your plots were made? Usually, the line in a qq-plot is simply a straight line connecting the dots at the 1st & 3rd quartile. Your lines look like a slope of 1 w/ intercept 0. Also, I take it the qq-plots are the residuals, but are the histograms of the residuals, or are they the marginal distributions of the indices? Can you say something about what the indices are? Eg, #3&4 seem to have a lower bound of 0. $\endgroup$ – gung - Reinstate Monica Nov 24 '14 at 20:41
-1
$\begingroup$

It would seem that the distribution of the response conforms to a Poisson distribution. Though I would say that the model itself should be modeled using a log link I am unsure if the lmer function allows for generalization of the residuals. However, I believe the correct extraction of residuals for count data should be 'Pearson'.One other thing to consider is that your abline() function is set through zero with a slope of one, in other words the reference line will never actually follow the true theoretical quantiles. Use the function qqline()in order to rectify that.

$\endgroup$
  • $\begingroup$ This answer is very brief by our standards. Could you give an explanation as to why you think this is appropriate? What would the next steps of the analysis be? $\endgroup$ – Silverfish Aug 25 '16 at 0:13
  • $\begingroup$ Sure, It would seem that the distribution of the response conforms to a Poisson distribution. Though I would say that the model itself should be modeled using a log link I am unsure if the lmer function allows for generalization of the residuals. However, I believe the correct extraction of residuals for count data should be 'Pearson'.One other thing to consider is that your abline() function is set through zero with an intercept of one, in other words the reference line will never actually follow the true theoretical quantiles. Use the function qqline()in order to rectify that. $\endgroup$ – Stan Mastrantonis Aug 25 '16 at 1:23
  • $\begingroup$ It's best to edit this information into your answer rather than leave it as a comment below - the "edit" button is at the bottom of your answer. $\endgroup$ – Silverfish Aug 25 '16 at 1:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.