+ Reply to Thread
Results 1 to 2 of 2

Thread: Adjust for overdispersion in glm family = binomial (logit) model

  1. #1
    Points: 82, Level: 1
    Level completed: 64%, Points required for next Level: 18

    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Adjust for overdispersion in glm family = binomial (logit) model




    I have an overdispersion problem in my model.. I have the following data:

    y= succes/fail (%)
    x= Var1 : Temperature data
    m1<-glm(cbind(succes,fail)~Var1, data=data, family = binomial(logit))

    HTML Code: 
    Call:
    glm(formula = cbind(succes, fail) ~ Var1, family = binomial(logit), 
        data = data)
    
    Deviance Residuals: 
         Min        1Q    Median        3Q       Max  
    -14.2244   -0.1595    1.8024    1.9983    6.9403  
    
    Coefficients:
                Estimate Std. Error z value Pr(>|z|)    
    (Intercept) 1.196658   0.098642   12.13   <2e-16 ***
    Var1           0.104118   0.004219   24.68   <2e-16 ***
    ---
    Signif. codes:  0 *** 0.001 ** 0.01 * 0.05 . 0.1   1
    
    (Dispersion parameter for binomial family taken to be 1)
    
        Null deviance: 2195.8  on 224  degrees of freedom
    Residual deviance: 1769.5  on 223  degrees of freedom
    AIC: 2008.8
    
    Number of Fisher Scoring iterations: 6

    I found a possible way to correct for the overdispersion:

    HTML Code: 
    sigma2<-sum(residuals(m1,type = "pearson")^2)/222
    summary(m1, dispersion=sigma2)
    
    Call:
    glm(formula = cbind(succes, fail) ~ Var1, family = binomial(logit), 
        data = data)
    
    Deviance Residuals: 
         Min        1Q    Median        3Q       Max  
    -14.2244   -0.1595    1.8024    1.9983    6.9403  
    
    Coefficients:
                     Estimate   Std. Error  z value  Pr(>|z|)    
    (Intercept)  1.19666    0.41038   2.916    0.00355 ** 
    Var1           0.10412    0.01755   5.932    3e-09 ***
    ---
    Signif. codes:  0 *** 0.001 ** 0.01 * 0.05 . 0.1   1
    
    (Dispersion parameter for binomial family taken to be 17.30784)
    
        Null deviance: 2195.8  on 224  degrees of freedom
    Residual deviance: 1769.5  on 223  degrees of freedom
    AIC: 2008.8
    
    Number of Fisher Scoring iterations: 6
    Clearly it did something with my model but I can't find any confirmation if this is the right way to do it... Does someone know if this is the right way? And if not.. what would be the best way to do it..? Thank you so much !

  2. #2
    Omega Contributor
    Points: 39,072, Level: 100
    Level completed: 0%, Points required for next Level: 0
    hlsmith's Avatar
    Location
    Not Ames, IA
    Posts
    7,075
    Thanks
    402
    Thanked 1,192 Times in 1,153 Posts

    Re: Adjust for overdispersion in glm family = binomial (logit) model


    Not completely familiar with R in this regard, so bare with me.


    Y in the first model is success/fail, so odds, making it a logistic reg given the logit transformation. How are you defining overdispersion in that model and how would it come about in a logistic model?
    Stop cowardice, ban guns!

+ Reply to Thread

           




Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts






Advertise on Talk Stats