检查R中的GLM摘要的解释 [英] Checking interpretation of GLM summary in R

查看:190
本文介绍了检查R中的GLM摘要的解释的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

只想检查我在做什么都是正确的!

Just want to check that what I'm doing is all correct!

我在几个分类为两个栖息地的地点(农田和湿地)都有鸟类计数.我只是想看看哪个栖息地的数量更高.

I have bird counts in several sites categorised into two habitats - farmland and wetland. I simply want to see which habitat has higher counts.

我正在使用具有Poisson函数的GLM(因为它们是计数数据):

I'm using a GLM with a Poisson function (as they are count data):

> mod <- glm(count ~ habitat, family = "poisson")

> summary(mod)


Call:
glm(formula = count ~ habitat, family = poisson)

Deviance Residuals: 
    Min       1Q   Median       3Q      Max  
-0.5868  -0.4603  -0.2496  -0.2141   2.8464  

Coefficients:
                            Estimate Std. Error z value Pr(>|z|)
(Intercept)                  -0.2695     1.0000  -0.269    0.788
habitatWetland                1.7331     1.0954   1.582    0.114

(Dispersion parameter for poisson family taken to be 1)

    Null deviance: 37.802  on 91  degrees of freedom
Residual deviance: 34.373  on 90  degrees of freedom
AIC: 48.987

Number of Fisher Scoring iterations: 6

到目前为止一切还好吗?

So far so good?

我的理解是(使用默认的对比),Intercept指的是栖息地:农田-因此,估计农田的平均数量为exp(-0.2695).估计的湿地平均数将为exp(1.7331).

My understanding is that (using the default contrasts) the Intercept refers to habitat:Farmland - so the estimated average count on farmland sites would be exp(-0.2695). The estimated average count on wetland would be exp(1.7331).

截距p值(0.788)给出了截距(即农田中的计数)显着大于零的概率(尽管我对此并不特别感兴趣).湿地的p值(0.114)给出了湿地的数量与截距不同(即与农田的数量不同)的可能性.因此,在这种情况下,两种栖息地类型之间没有显着差异(5%的水平).

The intercept p-value (0.788) gives the probability that the intercept (i.e. count in farmland) is significantly greater than zero (although I'm not particularly interested in this). The wetland p-value (0.114) gives the probability that the count in wetland is different from the intercept (i.e. different from the count in farmland). So in this case there is no significant (at the 5% level) difference between the two habitat types.

这一切正确吗?还有什么我应该考虑或做的不同的事情?

Is that all correct? Anything else I should be thinking of or doing differently?

推荐答案

关闭,但对于湿地,速率为exp(-0.2695 + 1.7331),并且您对p值的理解不正确. p值不是替代假设成立的概率;如果原假设是正确的,那么就有机会看到至少与观察到的数据一样极端的数据(并且您将在类似的情况下收集更多的数据).

Close but for wetland the rate is exp(-0.2695 + 1.7331), and your understanding of p-values is off. The p-value is not the probability that the alternative hypothesis is true; it is the chance of seeing data at least as extreme as observed if the null hypothesis were true (and you were to collect more data under similar circumstances).

截距的p值很少有用.根据其他系数的p值(0.114),很明显您没有证据表明湿地和农田之间存在差异.

The p-value for the intercept is rarely useful. From the p-value for the other coefficient (0.114), it is clear you do not have evidence of a difference between wetland and farmland.

这篇关于检查R中的GLM摘要的解释的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆