[R-sig-eco] Zero inflated data on some levels of a random factor in mixed models

Krista Takkis krista.takkis at gmail.com
Wed Sep 17 13:59:38 CEST 2014


Dear Mollie and Ben,

Thank you very much for your recommendations!

Best regards,
Krista

2014-09-17 3:33 GMT+03:00 Mollie Brooks <mbrooks at ufl.edu>:
> Dear Krista,
>
> glmmADMB will only model a zero inflation constant that equally applies to
> all species (i.e. no predictors for number of zeros). It sounds like in your
> case, zero inflation varies by species. The easiest thing to do is to model
> the zero/non-zero parts separately as you suggest.
>
> If n is nectar and dat is your data frame, then in lme4, this might look
> something like
>
> m0=glmer((n>0) ~ species + (1|plant), family=binomial, data=dat)
>
> m1=lmer(n ~ species + (1|plant),  data=subset(dat, n>0))
>
> Note, with only 4 species, it should be included as a fixed rather than
> random effect.
> Do you have repeated measures of individual flowers? If not, then there’s no
> need to include it as a random effect.
>
> Cheers,
> Mollie
> ------------------------
> Mollie Brooks, PhD
> Postdoctoral Researcher, Population Ecology Research Group
> Institute of Evolutionary Biology & Environmental Studies, University of
> Zürich
> http://www.popecol.org/team/mollie-brooks/
>
>
> On 15Sep 2014, at 9:41, Krista Takkis <krista.takkis at gmail.com> wrote:
>
> Dear all,
>
>
>
> I have a set of data on nectar volumes from four plant species. Two
> species have ample zeroes in the data (for one species almost 1/3 of
> the flowers had no nectar), but two species don’t have excessive
> zeroes in the data and have a normal distribution. I am trying to find
> out, what would be the correct way to model the trait responses in
> this situation. I would like to analyse all four species in one mixed
> model, but should I try to account for the zero inflated data, if the
> problem is only with half of the species? And if so, then how could I
> do it properly?
>
>   An answer to an earlier question on the topic of zero inflated data
> (https://stat.ethz.ch/pipermail/r-help/2014-May/374444.html) suggested
> to model the zero and non-zero data separately. With not too many
> zeroes in case of two species and wishing to combaine all four
> species, I probably cannot use this method in this case or could it be
> possible somehow? Till now I have used function glmmPQL (MASS) to
> model this trait with species/plant/flower as a random factor.
> However, as far as I know, this function does not allow to account for
> the zero inflated data. I found that MCMCglmm and glmmADMB would allow
> to account for zero inflated data, but before learning to use a new
> package I wanted to ask, whether this would be the correct way to
> approach this kind of data in the first place and whether there might
> be a way to do this using glmmPQL function?
>
>   Could you give me some suggestions, what might be the best way to
> deal with this kind of data?
>
>
>
> Thank you in advance,
>
>
>
> Krista Takkis
>
> Department of Geography
>
> University of the Aegean
>
> _______________________________________________
> R-sig-ecology mailing list
> R-sig-ecology at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-ecology
>
>



More information about the R-sig-ecology mailing list