on 10/31/2008 01:07 PM [EMAIL PROTECTED] wrote: > Dear fellows, > > I'm trying to extract the AIC statistic from a GLM model with quasipoisson > link. > The formula I'm referring to is > > AIC = -2(maximum loglik) + 2df * phi > > with phi the overdispersion parameter, as reported in: > > Peng et al., Model choice in time series studies os air pollution and > mortality. J R Stat Soc A, 2006; 162: pag 190. > > Unfortunately, the function logLik doesn't work for a quasipoisson link. > Do you know a fast method to extract the AIC for these models? > > Thanks in advance
I was under the impression that there is no log likelihood for quasi* family models, thus no AIC, which is why they are not calculated/printed in the glm() summary outputs. If you want to model overdispersed data and need the AIC, you should look at glm.nb() in MASS for a negative binomial model: library(MASS) ?glm.nb This would also avail you of the anova.glm() methods for comparing models, which the quasi* families would not. You might also want to look at: http://cran.r-project.org/web/packages/pscl/vignettes/countreg.pdf which is the vignette from the pscl package. HTH, Marc Schwartz ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.