[R-sig-ME] Peijian Shi

Ben Bolker bbolker at gmail.com
Wed Mar 25 14:31:11 CET 2015


shi_peijian <shi_peijian at ...> writes:

> 
> Dear Sir / Ms.,
 
> I am using lme4 to analyze the effects of three treatment levels,
> three seed types, six sites on the removal percentage of seeds over
> 20 days. Each day, six sites were randomly chose, so the six sites'
> locations are different from another day's. There are total 10 seed
> for each combination (Treatment * Type) for oberving the removal
> number.
 
> I think, Day should be a random effect and Site also a random effect. Then
I use the following code:
 
>     glmer(cbind(Removal, 10-Removal) ~ Type + Treatment + (1 | Day / Site),  
  family=binomial)
 
> My quesiton is whether (1|Day/Site) correct for my experiment? Each
> day, there were six random sites, and we observed the removal number
> per 10 seeds for the combinations (Treatment * Type).
 

  This looks about right, if you have unique sites.  If you wanted,
you could look for time trends by adding Day as continuous fixed
covariate; it's probably not going to make a very big difference,
but might improve model fit (normality of conditional modes) slightly.



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