best choice of GLMM for seed set data
Dear Bob, Thanks for introducing this nice paper. But it is interesting for me that now all articles which have treatments and interested to main factors they only reports main effects with their significance (Chisquare, LRT or F value with significance). How they got this output using GLMM in r (lme4 or nlme) then considering that most of them are not statistician to follow complicated way!. I thought it is very basic and simple question to have main effects results from glm or glmm. But it looks it is not easy way in R!. Warm regards, Mehdi
On Thu, Aug 27, 2015 at 6:59 PM, Bob O'Hara <bohara at senckenberg.de> wrote:
On 27/08/15 15:33, Mehdi Abedi wrote: Thanks Bob for reply. I have problem that when you have results of effect size i am not sure to how get only main effect without their levels data. I previously asked this simple question but i couldn't get clear answer. The question is simple: how we can have only temp, light and their interactions(similar like output of anova() without their levels. You can't: that's what the effect sizes are! For more on how to interpret them, see any good stats text, or this paper: <http://dx.doi.org/10.5735/086.046.0205> <http://dx.doi.org/10.5735/086.046.0205> Bob *Call:* glm(formula = cbind(A..hierochuntica, A..hierochunticano) ~ temp * light, family = binomial) Deviance Residuals: Min 1Q Median 3Q Max -4.4473 -1.1993 0.9904 2.0101 3.6663 Coefficients: Estimate Std. Error z value Pr(>|z|) (Intercept) 2.66616 0.14341 18.591 < 2e-16 *** temp20/30 0.08538 0.20671 0.413 0.679596 temp25/35 -0.67373 0.18001 -3.743 0.000182 *** lightlight 0.51189 0.23048 2.221 0.026350 * temp20/30:lightlight 0.62839 0.37291 1.685 0.091965 . temp25/35:lightlight 2.09080 0.43729 4.781 1.74e-06 *** --- Signif. codes: 0 ?***? 0.001 ?**? 0.01 ?*? 0.05 ?.? 0.1 ? ? 1 (Dispersion parameter for binomial family taken to be 1) Null deviance: 334.88 on 47 degrees of freedom Residual deviance: 209.30 on 42 degrees of freedom AIC: 331.56 Number of Fisher Scoring iterations: 6 this is by *anova(model,test="Chi")* Analysis of Deviance Table Model: binomial, link: logit Response: cbind(A..hierochuntica, A..hierochunticano) Terms added sequentially (first to last) Df Deviance Resid. Df Resid. Dev Pr(>Chi) NULL 47 334.88 temp 2 10.144 45 324.73 0.006271 ** light 1 86.860 44 237.87 < 2.2e-16 *** temp:light 2 28.569 42 209.30 6.255e-07 *** --- Signif. codes: 0 ?***? 0.001 ?**? 0.01 ?*? 0.05 ?.? 0.1 ? ? 1 *anova(model, test="F")* Analysis of Deviance Table Model: binomial, link: logit Response: cbind(A..hierochuntica, A..hierochunticano) Terms added sequentially (first to last) Df Deviance Resid. Df Resid. Dev F Pr(>F) NULL 47 334.88 temp 2 10.144 45 324.73 5.0718 0.006271 ** light 1 86.860 44 237.87 86.8597 < 2.2e-16 *** temp:light 2 28.569 42 209.30 14.2847 6.255e-07 *** --- Signif. codes: 0 ?***? 0.001 ?**? 0.01 ?*? 0.05 ?.? 0.1 ? ? 1 Warning message: In anova.glm(model, test = "F") : using F test with a 'binomial' family is inappropriate Warm regards, Mehdi On Thu, Aug 27, 2015 at 2:38 PM, Bob O'Hara <bohara at senckenberg.de> wrote:
On 27/08/15 11:57, Mehdi Abedi wrote:
Dear Thierry, Yes i am using (success, failure) but in this case i need to change all data frame. I was thinking to use codes which is not necessary to create new column when you have a ll of species. Because we know success(germinated seeds) and we know failure (Total seeds - success(germinated seeds)). Yes i used codes with ANOVA but there is no P- value for study. model2<- glmer(cbind(germinated, Nongerminated) ~ temp *light + (1|Replication ), data=growthdata, + family=binomial)
anova(model2)
Analysis of Variance Table
Df Sum Sq Mean Sq F value
temp 2 30.600 15.300 15.300
light 1 46.231 46.231 46.231
temp:light 2 22.877 11.439 11.439
p-values are difficult. See here: <http://glmm.wikidot.com/faq> Better to stick to reporting your effect sizes: your analysis of deviance only tells you if you have enough data to see a difference, not how big the differences are. Also, if Replication is 1:nrow(growthdata), you could use a simple GLM and estimate your over-dispersion term (the residual deviance divided by the residual sum of squares should be OK). You can use this to correct the standard errors with summary(glm.obj, dispersion=overdisp). Bob Warm regards,
Mehdi On Thu, Aug 27, 2015 at 1:56 PM, Thierry Onkelinx < thierry.onkelinx at inbo.be> wrote: Dear Mehdi,
Assuming that you want to model the probability of germination, yes. Note that cbind(seed, 100) is WRONG syntax. CORRECT syntax: cbind(n_success, n_failure) Have you tried anova(your.model)? Best regards, ir. Thierry Onkelinx Instituut voor natuur- en bosonderzoek / Research Institute for Nature and Forest team Biometrie & Kwaliteitszorg / team Biometrics & Quality Assurance Kliniekstraat 25 1070 Anderlecht Belgium To call in the statistician after the experiment is done may be no more than asking him to perform a post-mortem examination: he may be able to say what the experiment died of. ~ Sir Ronald Aylmer Fisher The plural of anecdote is not data. ~ Roger Brinner The combination of some data and an aching desire for an answer does not ensure that a reasonable answer can be extracted from a given body of data. ~ John Tukey 2015-08-27 11:19 GMT+02:00 Mehdi Abedi < <abedimail at gmail.com> abedimail at gmail.com>:
Dear Thierry and Mariano, Could we apply these glmer for seed germination in petridishes which the total number of seeds is defined as well? like cbind(seeds,100). In addition what is the simple way to get ANOVA liked tables (i think
with
Chisquare would be better test than F value) for these test with having
P-
value as well? Warm regards, Mehdi On Thu, Aug 27, 2015 at 12:20 PM, Thierry Onkelinx <thierry.onkelinx at inbo.be> wrote:
Dear Mariano, The binomial distribution (not error family) assumes that you have a number of successes and failures. If the potential number of seeds is fixed by the morphology of the plant, then a binomial distribution is reasonable. If the potential number of seeds is dictated by morphology, then I'd rather see it as counts and use a Poisson or negative binomial. The correct syntax in the binomial case is cbind(success, failure). Or in your case cbind(seeds, 4 - seeds). Best regards, ir. Thierry Onkelinx Instituut voor natuur- en bosonderzoek / Research Institute for Nature and Forest team Biometrie & Kwaliteitszorg / team Biometrics & Quality Assurance Kliniekstraat 25 1070 Anderlecht Belgium To call in the statistician after the experiment is done may be no more than asking him to perform a post-mortem examination: he may be able to say what the experiment died of. ~ Sir Ronald Aylmer Fisher The plural of anecdote is not data. ~ Roger Brinner The combination of some data and an aching desire for an answer does not ensure that a reasonable answer can be extracted from a given body of data. ~ John Tukey 2015-08-26 20:32 GMT+02:00 Mariano Devoto < <mdevoto at agro.uba.ar> mdevoto at agro.uba.ar>:
Dear all. I am analysing data from a field experiment on a crop pollination. I want to test if there are differences in the number of seeds per fruit between three treatments. The experimental design consists
of
four separate sites where small subplots (ca. 5 plants each) received
one of the treatments. In each site, 8 subplots were allocated to
treatment
A,
8 to treatment B and 4 to treatment C. When fruits were ripe I
collected
all plants from each subplot and counted stems, fruits per stem and
seeds per fruit. I think a GLMM is the best way to go as I expect random effects related to field and subplot identity, and my response variable
(number
of
seeds) is clearly non-normal. My main concern is the choice of the
error
family. As I?m counting seeds I first though of a Poisson model, but
then realized that seed numbers only range from 0 to 4. I am now
considering
using a binomial model such as this:
glmer(cbind(seeds,4) ~ treatment + (1|site) + (1|subplot),
data=seed.data,
family=binomial)
Does this make sense?
I would welcome any advice before hitting ?SEND? in Tinn-R :-).
--
*Mariano Devoto*
[[alternative HTML version deleted]]
_______________________________________________ R-sig-ecology mailing list R-sig-ecology at r-project.org https://stat.ethz.ch/mailman/listinfo/r-sig-ecology
_______________________________________________ R-sig-ecology mailing list R-sig-ecology at r-project.org https://stat.ethz.ch/mailman/listinfo/r-sig-ecology
-- Mehdi Abedi Department of Range Management Faculty of Natural Resources & Marine Sciences Tarbiat Modares University (TMU) 46417-76489, Noor Mazandaran, IRAN mehdi.abedi at modares.ac.ir Homepage Tel: +98-122-6253101 Fax: +98-122-6253499
-- Bob O'Hara Biodiversity and Climate Research Centre Senckenberganlage 25 D-60325 Frankfurt am Main, Germany Tel: +49 69 7542 1863 Mobile: +49 1515 888 5440 WWW: http://www.bik-f.de/root/index.php?page_id=219 Blog: http://blogs.nature.com/boboh Journal of Negative Results - EEB: <http://www.jnr-eeb.org> www.jnr-eeb.org
_______________________________________________ R-sig-ecology mailing list R-sig-ecology at r-project.org https://stat.ethz.ch/mailman/listinfo/r-sig-ecology
-- *Mehdi Abedi Department of Range Management* *Faculty of Natural Resources & Marine Sciences * *Tarbiat Modares University (TMU) * *46417-76489, Noor* *Mazandaran, IRAN * * <Mehdi.abedi at modares.ac.ir>mehdi.abedi at modares.ac.ir <mehdi.abedi at modares.ac.ir>* *Homepage <http://www.modares.ac.ir/en/Schools/nat/Academic_Staff/%7Emehdi.abedi>* *Tel: +98-122-6253101 * *Fax: +98-122-6253499* -- Bob O'Hara Biodiversity and Climate Research Centre Senckenberganlage 25 D-60325 Frankfurt am Main, Germany Tel: +49 69 7542 1863 Mobile: +49 1515 888 5440 WWW: http://www.bik-f.de/root/index.php?page_id=219 Blog: http://blogs.nature.com/boboh Journal of Negative Results - EEB: www.jnr-eeb.org
*Mehdi Abedi Department of Range Management* *Faculty of Natural Resources & Marine Sciences * *Tarbiat Modares University (TMU) * *46417-76489, Noor* *Mazandaran, IRAN * *mehdi.abedi at modares.ac.ir <Mehdi.abedi at modares.ac.ir>* *Homepage <http://www.modares.ac.ir/en/Schools/nat/Academic_Staff/~mehdi.abedi>* *Tel: +98-122-6253101 * *Fax: +98-122-6253499* [[alternative HTML version deleted]]