Skip to content

Results from GLMM, error bars for predictions

5 messages · Thierry Onkelinx, Quentin Schorpp, Ben Bolker

#
Dear Quentin,

Please keep the mailing list in cc.

Dropping non significant terms from an ordered factor is not ok. That would
change the interpretation of the factor. You wouldn't drop non significant
levels of an unordered factor either.

Ben's solution is about multiple comparisons with random (and fixed)
effects. You're only dealing with multiple comparisons with fixed effects.
So glht() will do the trick.

Try plotting the predicted values for all relevant combinations of the
fixed effects. I find that easier to interpret than just a bunch of
coefficients.

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-04-27 9:30 GMT+02:00 Quentin Schorpp <quentin.schorpp at ti.bund.de>:

  
  
#
Hello,

Thank you for writing,

I tried what you said, but simple addition of "offset(log(0.25))" did 
not work. Hence I created a factor "area" expressed as m? with the value 
0.25 for all observations:
  data$area <- rep(0.25, 180)
and added offset(log(area)) to the model formula.

Ok, plotting the predicted values for all relevant combinations of the 
fixed effects was also my intention. However, the problem with the 
errorbars occured. Or is it a faulty assumption of mine, that plots of 
predicted values need error-bars?

I'm sorry, i recognized that the answer was only adressed to you, after 
i send the mail. Then i send it again to the Mailing List, i hope it 
won't get to chaotic right now. Now i used "answer all"

kind regards



Am 27.04.2015 um 10:50 schrieb Thierry Onkelinx:

  
    
#
Dear Quentin,

IMHO, errorbars are more important than p-values. So yes, you need to
present them. Here is an example

library(glmmADMB)
om <- glmmadmb(SiblingNegotiation~ FoodTreatment * SexParent
+(1|Nest)+offset(log(BroodSize)),zeroInflation=TRUE,family="nbinom",data=Owls)
newdata <- expand.grid(
  FoodTreatment = unique(Owls$FoodTreatment),
  SexParent = unique(Owls$SexParent),
  BroodSize = 4
)
newdata <- cbind(newdata, predict(om, newdata = newdata, interval =
"confidence"))

library(ggplot2)
ggplot(newdata, aes(x = FoodTreatment, colour = SexParent, y = exp(fit),
ymin = exp(lwr), ymax = exp(upr))) + geom_errorbar(position =
position_dodge(1)) + geom_point(position = position_dodge(1))

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-04-27 11:30 GMT+02:00 Quentin Schorpp <quentin.schorpp at ti.bund.de>:

  
  
#
Dear Thierry,

There's one thing that i don't understand.
Why do you plot the vertical line in
ggplot(pairwise.ci <http://pairwise.ci>, aes(y = lhs, x = exp(estimate), 
xmin = exp(lwr), xmax = exp(upr))) + geom_errorbarh() + geom_point() + 
geom_vline(xintercept = 1)

and how can i transfer this to other models?

kind regards,
Quentin

Am 27.04.2015 um 11:48 schrieb Thierry Onkelinx:

  
    
#
Quentin Schorpp <quentin.schorpp at ...> writes:
[Sorry to remove context, gmane doesn't like it ...]

  Since the model parameters are back-transformed (i.e.
exponentiated), the null value of the parameters (no effect)
is exp(0)=1; the horizontal line is showing the null value.
Thus for example if the 95% confidence intervals cross the
dotted line, the corresponding effect is not statistically
significant at p=0.05.