Study design

So I have put out 80 hare traps in a forest area of 50 km^2. There forest area is split into 4 zones. Each zone is expected to be different because of different pollution input levels. In each zone there are 20 traps. At the location of each trap I have measured several environmental variables e.g Pb, Zn,... in the soil. Each trap has caught different number of hares. So as I understand this is what is called unbalanced design. What would be correct term in the "design terminology" to give this type of design?

Quantitative methods

I'm doing PCA on the environmental variables and using the principal components (PC1 - PC3) that explain most of the variance (in the environmental variables) as explanatory variables in linear regression. In the linear regression I'm using rabbit weight as a response variable. I'm merging the weight-data with the PC-data, so that for each trap-location there is 1 unique value from PC1, PC2 and PC3. So in the matrix with the merged rabbit-PCA-data each value of PC1, PC2 and PC3, appear several times for each trap, depending on the number of rabbits caught at each trap. Each rabbit weight appears mostly only once in this matrix, except where it has been recaught in a few cases. I have zone as a factor variable. As I see it a linear mixed effects model may be more appropiate here? I'm trying to find out how much of the weight variation can be explained by the environmental variables. I'd love suggestions if you know any studies/papers that have used this method or more appropriate methods to achieve the objective with this type of study design.


1 Answer 1


You will want a linear mixed effect model. The lme4 and glmmTMB packages in R are fairly easy to use. It sounds like you have repeated measurements on tagged hares, multiple hares per trap, and you may want to include zones in the model or perhaps the geographic coordinates. You will want a model like lmer(mass ~ PC1 + PC2 + PC3 + (1|hare) + (1|trap) + (1|zone), data = ...)

If hares don't vary in weight much you could just pick 1 capture to simplify things. If the study occurred over several months hare recaptures would maybe be more informative, along with include information on time. Note that if a lot of the variation in the PCs maps to zone then including it in the model may make interpretation harder. Using geographic location could be used instead of zone and probably be a better model. I don't know that code off the top of my head though. You'd use the nlme package or possibly glmmTMB to include spatial autocorrelation. Log(mass) may be useful to improve normality of the residuals. Perhaps you've done this already, but color coding PCA results by zone could be informative to confirm geographic structure of the data. I have demo code for this here using the vegan package: https://rpubs.com/brouwern/veganpca Kmeans and hierarchical clustering are also good for exploratory work

  • $\begingroup$ @N Brouwer: Thanks alot for the the spot-on answer, this is very helpful. Would I still use a mixed effects model if I'm mainly interested in "studying" the direct effects, not the random ones? $\endgroup$
    – Cordex
    Apr 14 at 17:13
  • 1
    $\begingroup$ Yes. Random effects typically are used to accommodate aspects of study design that you aren't interested in per se but need accommodate. $\endgroup$
    – N Brouwer
    Apr 14 at 22:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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