Skip to content
Prev 7022 / 20628 Next

how to look at the effect of a variable I need to control for/ random effects

Hi Andrew,
thank you very much for your reply and help. I set up the dummy 
variables for n-1 census and basically the values of AIC as well as the 
estimates didn't really differ when comparing a model with dummy 
variables and a model with census (as factor) placed as a fixed 
variable. Running an anova for both models showed they were similar. 
When plotting res. vs. fitt, the same.
glmm.abspre<-glmer(abs.pres~census+avail.surface+ (1|tree), 
data=db.e_St, family=binomial(link=logit))
glmm.asbpre.dum<-glmer(abs.pres~D2+D3+D4+D5+avail.surface+ (1|tree), 
data=db.e_St, family=binomial(link=logit))
the variables, just to recall:
*abs.pre*: binary; *census*: factor, 5 levels; 
*avail.surface*:continuous var.; *tree*:factor, ~89 levels; *spp*:~89 levels

Here some questions out of this, for you or anybody that might want to 
spare some time, which I would certainly be grateful for:
Would this mean that my actual model, should be "census" (as factor) as 
fixed effect:
glmm.abspre<-glmer(abs.pres~Fcensus*avail.surface+ (1|tree), 
data=db.e_St, family=binomial(link=logit))
Or should I instead have "census" as a standardized continuous values? 
(which in an anova shows difference, DF: -6 and only 4 points more in 
the AIC).
Because if I use dummy variables, would I be able to place a term of 
interaction between time (eitherway as a factor or a continuous value) 
and avail.surface?.

At last, a consultation, about random effects:
(1|tree/spp): does this means that the species ("spp") occurring in tree 
1 are not correlated to each other in time?
(1|tree) +(1|spp): does this means that both random factors are 
independent sources of variation?
My question is, considering that my reasoning above makes sense, what 
would be the best way to fit the random effect "spp" in a way that does 
not indicate either of the above?.

Thanks again for your time,

glenda mendieta-leiva
PhD candidate
University of Oldenburg, Germany
Smithsonian Tropical research institute
On 18/11/2011 17:50, Andrew Miles wrote: