Allometric test

210 views
Skip to first unread message

Fabio Leonardo Meza Joya

unread,
May 8, 2023, 1:24:19 AM5/8/23
to geomorph R package

Hi everyone,

I’m wondering if someone here can give me some clarification/advice on analysing the influence of size in shape. I am analysing the pronotum shape of two different genetic lineages of grasshoppers. I have run the following code in Geomorph and the results suggest there is a weak but significant allometric effect.
             
gen.allo <- procD.lm(data=allometry, shape~log(size), RRPP=FALSE, logsz=T, iter=1000) 

summary(gen.allo)

                    Df     SS        MS       Rsq      F          Z           Pr(>F)    
log(size)    1       0.006   0.006   0.041  4.184   3.118   4e-04 ***
Residuals  99     0.153   0.002   0.959                         
Total          100   0.159

Then, I run two alternative models to test for common/unique allometries between lineages to check if my data requires size correction.

unique <- procD.lm(data=allometry, shape~log(size)*group, RRPP=FALSE, logsz=T, iter=1000)
summary(unique)

common <- procD.lm(data=allometry, shape~log(size)+group, RRPP=FALSE, logsz=T, iter=1000)
summary(common)

anova(common, unique, print.progress=FALSE) 

                                                          ResDf   Df   RSS       SS        MS        Rsq      F           Z         Pr(>F)
shape ~ log(size) + group (Null)  98         1      0.133                             0.000                                 
shape ~ log(size) * group             97         1      0.131   0.002   0.002   0.010   1.156   0.549  0.292
Total                                                 100               0.15965                                            

Based on this results, it seems that both lineages share common allometry given a non-significant interaction term (shape x lineage) in the group.unique model (R2 = 0.00979, Z = 0.5373, P = 0.297), meaning size correction would be appropriated. However, the Anova results (above) seem to indicate both models lack explanatory power (Am I right or am I missing something here?).

I have gone through previous threads about removing allometric effects but I'm not sure if it is the best way to proceed with my dataset as my main target here is to use naïve clustering on shape data and then check if phenotypic differentiation is coupled with major neutral genetic structuring. Any comments/advice would be very much appreciated!

Cheers, Leo

agne89

unread,
May 8, 2023, 12:37:32 PM5/8/23
to geomorph R package
Hi Leo,

in your ANOVA you are comparing the models with and without the interactions to each other. To have a more complete picture of what is the best model, so to check if the groups have parallel but distinct allometric slopes in this case or a single one you need to add your first model (gen.allo) to the anova as the null model (so in first position before common).
To learn more about how interpret these kind of analysis I'd recommend this book:
It can be found used on Amazon and it has very helpful graphics that explain how to interpret ANOVA analyses.

Best wishes,
Agnese

Fabio Leonardo Meza Joya

unread,
May 8, 2023, 5:24:04 PM5/8/23
to geomorph R package
Hi Agnese, many thanks for your comments and recommendations, indeed appreciated :)

I've run an Anova following your comments,

anova(gen.allo, group.common, group.unique, print.progress=FALSE)

Here are the results,

                                                   ResDf   Df    RSS      SS        MS      Rsq       F           Z           P  Pr(>F)
shape ~ log(size) (Null)        99          1      0.153                             0.000                         
shape ~ log(size) + group    98          1      0.133   0.021   0.021   0.127   5.166   5.707   9.999e-05
shape ~ log(size) * group     97          2      0.131   0.022   0.011   0.138   8.173   5.955   9.999e-05
Total                                        100                 0.160                                                   
          
As far I understand, both models are quite similar, but the unique allometry model is slightly better than the common allometry model (Am I right?). Given this results, is it worthy to apply size correction to my data? Any comments/advice would be very much appreciated!

Cheers, Leo

agne89

unread,
May 9, 2023, 12:34:47 PM5/9/23
to geomorph R package
Hi Leo,

I would say that the 2 models are basically identical - meaning that the common model explains as much as the unique one - therefore the common model should be preferred.
Although it is a bit unusual in my experience to have 2 models with same Z scores and p-values so I looked back at your code. 

There are 2 things that I would change. 
First since you have already log transformed size in the formula you don't have to add logz=TRUE, that will either do nothing or try to transform something that is already log-transformed.
Second, why did you use RRPP=FALSE? Usually RRPP=TRUE is used since it works better (see the procD.lm help file for examples and a full explanation).
After you change these 2 things in the models I would try to rerun the anova and see what results you get, I suspect they might be slightly different. 

Anyway, generally speaking, you do not need to "correct" the data for size, it depends on what you want to do with the data, so what questions you are trying to answer. Keep in mind that it doesn't make much sense to use residuals obtained by a unique allometry for further analysis as they are calculated using different regressions, and therefore these data will have marked group differences. If you want to look at shape independent of size for example in a PCA I would still use the residuals of the common allometry model. I recommend this paper by Klingenberg 2016 (https://link.springer.com/article/10.1007/s00427-016-0539-2) if you want to learn more about allometric correction in GM analysis and see if it would be appropriate for your specific research question.

Cheers,
Agnese

Fabio Leonardo Meza Joya

unread,
May 10, 2023, 12:05:22 AM5/10/23
to geomorph R package
Hi Agnese, many thanks for clarifying the landscape! Indeed appreciated! 

Cheers, Leo

Reply all
Reply to author
Forward
0 new messages