[R-sig-eco] Question about GLM post hoc and chi square

Luis Fernando García luysgarcia at gmail.com
Sat Jun 14 03:05:28 CEST 2014


Dear all,

I am making an analysis using a GLM using three explanatory variables and a
response variable. I need to obtain a table similar to this one,
http://postimg.org/image/5sau79wlt/r

 nevertheless, I have not been able to do it. I am having a hard time
specially getting the chi square values. I would like to know how to obatin
them.

I also would like to know what function could help me to make ad hoc
comparisons for single variables and interactions.

If any of you knows how to do both estimations, I would really appreciate
it.

All the best!!!

This is my script
a=read.table("ricis3.txt",header=T)
attach(a)
model7=glm(Count~Sex+Time+Behaviour+Sex*Time+Sex*Behaviour+Time+Behaviour*Sex,family=poisson)
summary(model7)
-------------- next part --------------
Sex	Time	Behaviour	Count
Male	Night	Exploring	189
Male	Night	Interacting	11
Male	Night	Feeding	170
Male	Night	Mating	13
Male	Night	Resting	240
Male	Day	Exploring	58
Male	Day	Interacting	1
Male	Day	Feeding	12
Male	Day	Mating	3
Male	Day	Resting	399
Female	Night	Exploring	187
Female	Night	Interacting	10
Female	Night	Feeding	95
Female	Night	Mating	8
Female	Night	Resting	175
Female	Day	Exploring	45
Female	Day	Interacting	6
Female	Day	Feeding	10
Female	Day	Mating	4
Female	Day	Resting	406
Immature	Night	Exploring	186
Immature	Night	Interacting	15
Immature	Night	Feeding	175
Immature	Night	Resting	200
Immature	Day	Exploring	68
Immature	Day	Interacting	8
Immature	Day	Feeding	6


More information about the R-sig-ecology mailing list