I'm performing a GLM, the response variable is number of individuals, and response variables are
-
habitat (4 levels) and
-
season (4 levels).
I need some help since I know the summary()
shows p-values but not for the first (alphabetical) level of factor. I mean, I don't know how to interpret that the Intercept has a significant p-value. I can't reach a biological explanation for this model. Hope you can help me …
Call:
glm(formula = individuals ~ habitat + season, family =
poisson(link = "log"),
data = data)
Deviance Residuals:
Min 1Q Median 3Q Max
-2.85859 -0.51541 -0.08508 0.36497 2.29058
Coefficients:
Estimate Std. Error z value Pr(>|z|)
(Intercept) 1.6774 0.1624 10.331 < 2e-16 ***
habitatDeciduous 0.1340 0.1696 0.790 0.42950
habitatSemiDeciduous 0.2102 0.1675 1.255 0.20933
habitatWetland -0.1861 0.2039 -0.912 0.36151
seasondry2018 -0.1138 0.1510 -0.753 0.45123
seasonwet2016 -0.2699 0.1576 -1.713 0.08677 .
seasonwet2017 -0.4383 0.1656 -2.647 0.00813 **
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
(Dispersion parameter for poisson family taken to be 1)
Null deviance: 78.487 on 63 degrees of freedom
Residual deviance: 64.556 on 57 degrees of freedom
AIC: 287.77
Best Answer
When independent variables are categorical, one level of each is chosen as a refernce level. By default, R choose the first one in alphabetical order. The other levels are compared to that level.
The intercept is the parameter estimate for when all the other variables are 0 -- in this case, when the other two variables are at the reference level.
You can change the defaults, but R questions are off-topic here.