[R-sig-ME] query on binomial glm of pollination experiment

Mariano Devoto mdevoto @end|ng |rom @gro@ub@@@r
Thu Feb 20 20:38:51 CET 2020


Dear all,

I am trying to assess the effect of five pollination treatments on a
plant's fruit set. The data set is not too good (few samples and unbalanced
-sadly we lost many field samples to vandalism-, quite a few zeros). I
counted the n of flowers that received each treatment and the number of
fruits at the end of the experiment. I am using a binomial model.
Furthermore, given that several (though not all) plants received all the
treatments I'd like to include a random factor to account for between-plant
variation. I tried models with and without a random factor but results
either look awkward (particularly post hoc comparisons in model M1) or the
model does not converge (M2).

I'll be grateful for any advice on how to reliably test the significance of
the treatments and do multiple pairwise comparisons.

Thanks in advance for your help!

Here is the code to load the data and perform the analysis. The data set is
read from a Google sheet.

#loading data and curating data
require(RCurl); require(lme4); require(multcomp)
my.file <- getURL("
https://docs.google.com/spreadsheets/d/e/2PACX-1vSu7V5v00cpQ_SFZq5ajS-RUPCgRYf0q249SW3rh9g2q87h7awYOsgBX4xIRDGWQff4Jy6IRnSLuaxH/pub?output=csv
")
sistrep <- read.csv(textConnection(my.file), head=T)
str(sistrep)
nofruits <- sistrep$flowers-sistrep$fruits #calculates n of failed
pollinations

#plot the data
prop <- sistrep$fruits/sistrep$flowers
boxplot(prop ~ treatment, data=sistrep, las=1, ylab="Fruit set (n fruits/n
flowers)", boxwex=0.6)

#and here are the models & post hoc comparisons
M0 <- glm(cbind(fruits, nofruits) ~ 1, data = sistrep, family = "binomial")
M1 <- glm(cbind(fruits, nofruits) ~ treatment, data = sistrep, family =
"binomial")
M2 <- glmer(cbind(fruits, nofruits) ~ treatment + (1|plant), data =
sistrep, family = "binomial")
summary(M0)
summary(M1)
anova(M0,M1)
summary(M2)

summary(glht(M1, mcp(treatment = "Tukey", interaction_average=F)))
---------------------------------------------
Dr. Mariano Devoto

Profesor Adjunto - Cátedra de Botánica General, Facultad de Agronomía de la
UBA
Investigador Adjunto del CONICET

Av. San Martín 4453 - C1417DSE - C. A. de Buenos Aires - Argentina
+5411 5287-0069
*https://www.researchgate.net/profile/Mariano_Devoto
<https://www.researchgate.net/profile/Mariano_Devoto>*

	[[alternative HTML version deleted]]



More information about the R-sig-mixed-models mailing list