summaryOD {AICcmodavg}R Documentation

Display Model Summary Corrected for Overdispersion

Description

This function displays the estimates of a model with standard errors corrected for overdispersion for a variety of model classes. The output includes either confidence intervals based on the normal approximation or Wald hypothesis tests corrected for overdispersion.

Usage

summaryOD(mod, c.hat = 1, conf.level = 0.95, 
          out.type = "confint", ...)

## S3 method for class 'glm'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitOccu'
summaryOD(mod, c.hat = 1, conf.level = 0.95,
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitColExt'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitOccuRN'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitPCount'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitPCO'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitDS'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitGDS'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitOccuFP'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitMPois'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitGMM'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitGPC'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitOccuMulti'
summaryOD(mod, c.hat = 1, conf.level = 0.95,
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitOccuMS'
summaryOD(mod, c.hat = 1, conf.level = 0.95,
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitOccuTTD'
summaryOD(mod, c.hat = 1, conf.level = 0.95,
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitMMO'
summaryOD(mod, c.hat = 1, conf.level = 0.95,
     out.type = "confint", ...)

## S3 method for class 'unmarkedFitDSO'
summaryOD(mod, c.hat = 1, conf.level = 0.95,
     out.type = "confint", ...)

## S3 method for class 'glmerMod'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'maxlikeFit'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'multinom'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

## S3 method for class 'vglm'
summaryOD(mod, c.hat = 1, conf.level = 0.95, 
     out.type = "confint", ...)

Arguments

mod

an object of class glm, glmmTMB, maxlikeFit, mer, merMod, multinom, vglm, and various unmarkedFit classes containing the output of a model.

c.hat

value of overdispersion parameter (i.e., variance inflation factor) such as that obtained from c_hat, mb.gof.test, or Nmix.gof.test.

conf.level

the confidence level (1 - \alpha) requested for the computation of confidence intervals.

out.type

the type of summary requested for each parameter estimate. If out.type = "confint", computes confidence intervals corrected for overdispersion, whereas out.type = "nhst" conducts null-hypothesis statistical testing corrected for overdispersion.

...

additional arguments passed to the function.

Details

Overdispersion occurs when the variance in the data exceeds that expected from a theoretical distribution such as the Poisson or binomial (McCullagh and Nelder 1989, Burnham and Anderson 2002). When the model is correct, small values of c-hat (1 < c-hat < 4) can reflect minor deviations from model assumptions (Burnham and Anderson 2002). In such cases, it is possible to adjust standard errors of parameter estimates by multiplying with sqrt(c.hat) (McCullagh and Nelder 1989). This is the correction applied by summaryOD.

Depending on the type of summary requested, i.e., out.type = "confint" or out.type = "nhst", summaryOD will return either confidence intervals based on the normal approximation or Wald tests for each parameter estimate (Agresti 1990).

For binomial distributions, note that values of c.hat > 1 are only appropriate with trials > 1 (i.e., success/trial or cbind(success, failure) syntax). The function supports different model types such as Poisson GLM's and GLMM's, single-season occupancy models (MacKenzie et al. 2002), dynamic occupancy models (MacKenzie et al. 2003), or N-mixture models (Royle 2004, Dail and Madsen 2011).

Value

summaryOD returns an object of class summaryOD as a list with the following components:

out.type

the type of output requested by the user.

c.hat

the c.hat estimate used to adjust standard errors.

conf.level

the confidence level used to compute confidence intervals around the estimates.

outMat

the output of the model corrected for overdispersion organized in a matrix.

Author(s)

Marc J. Mazerolle

References

Agresti, A. (2002) Categorical Data Analysis. Second edition. John Wiley and Sons: New Jersey.

Burnham, K. P., Anderson, D. R. (2002) Model Selection and Multimodel Inference: a practical information-theoretic approach. Second edition. Springer: New York.

Dail, D., Madsen, L. (2011) Models for estimating abundance from repeated counts of an open population. Biometrics 67, 577–587.

MacKenzie, D. I., Nichols, J. D., Lachman, G. B., Droege, S., Royle, J. A., Langtimm, C. A. (2002) Estimating site occupancy rates when detection probabilities are less than one. Ecology 83, 2248–2255.

MacKenzie, D. I., Nichols, J. D., Hines, J. E., Knutson, M. G., Franklin, A. B. (2003) Estimating site occupancy, colonization, and local extinction when a species is detected imperfectly. Ecology 84, 2200–2207.

Mazerolle, M. J. (2006) Improving data analysis in herpetology: using Akaike's Information Criterion (AIC) to assess the strength of biological hypotheses. Amphibia-Reptilia 27, 169–180.

McCullagh, P., Nelder, J. A. (1989) Generalized Linear Models. Second edition. Chapman and Hall: New York.

Royle, J. A. (2004) N-mixture models for estimating population size from spatially replicated counts. Biometrics 60, 108–115.

See Also

c_hat, mb.gof.test, Nmix.gof.test, anovaOD

Examples

##anuran larvae example from Mazerolle (2006)
data(min.trap)
##assign "UPLAND" as the reference level as in Mazerolle (2006)          
min.trap$Type <- relevel(min.trap$Type, ref = "UPLAND") 

##run model
m1 <- glm(Num_anura ~ Type + log.Perimeter + Num_ranatra,
          family = poisson, offset = log(Effort),
          data = min.trap) 

##check c-hat for global model
c_hat(m1) #uses Pearson's chi-square/df

##display results corrected for overdispersion
summaryOD(m1, c_hat(m1))
summaryOD(m1, c_hat(m1), out.type = "nhst")

##example with occupancy model
## Not run: 
##load unmarked package
if(require(unmarked)){
   
   data(bullfrog)
     
   ##detection data
   detections <- bullfrog[, 3:9]

   ##assemble in unmarkedFrameOccu
   bfrog <- unmarkedFrameOccu(y = detections)
     
   ##run model
   fm <- occu(~ 1 ~ 1, data = bfrog)

   ##check GOF
   ##GOF <- mb.gof.test(fm, nsim = 1000)
   ##estimate of c-hat:  1.89

   ##display results after overdispersion adjustment
   summaryOD(fm, c.hat = 1.89)
   summaryOD(fm, c.hat = 1.89, out.type = "nhst")

   detach(package:unmarked)
}

## End(Not run)

[Package AICcmodavg version 2.3-3 Index]