Custom Computation of AIC, AICc, QAIC, and QAICc from User-supplied Input
This function computes Akaike's information criterion (AIC), the second-order AIC (AICc), as well as their quasi-likelihood counterparts (QAIC, QAICc) from user-supplied input instead of extracting the values automatically from a model object. This function is particularly useful for output imported from other software.
the value of the model log-likelihood.
the number of estimated parameters in the model.
the sample size required to compute the AICc or QAICc.
value of overdispersion parameter (i.e., variance inflation factor)
such as that obtained from
AICc computes one of the following four information criteria:
Akaike's information criterion (AIC, Akaike 1973), the second-order or small sample AIC (AICc, Sugiura 1978, Hurvich and Tsai 1991), the quasi-likelihood AIC (QAIC, Burnham and Anderson 2002), and the quasi-likelihood AICc (QAICc, Burnham and Anderson 2002).
AICc returns the AIC, AICc, QAIC, or QAICc, or the number of
estimated parameters, depending on the values of the arguments.
The actual (Q)AIC(c) values are not really interesting in themselves, as they depend directly on the data, parameters estimated, and likelihood function. Furthermore, a single value does not tell much about model fit. Information criteria become relevant when compared to one another for a given data set and set of candidate models.
Marc J. Mazerolle
Akaike, H. (1973) Information theory as an extension of the maximum likelihood principle. In: Second International Symposium on Information Theory, pp. 267–281. Petrov, B.N., Csaki, F., Eds, Akademiai Kiado, Budapest.
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.
Hurvich, C. M., Tsai, C.-L. (1991) Bias of the corrected AIC criterion for underfitted regression and time series models. Biometrika 78, 499–509.
Lebreton, J.-D., Burnham, K. P., Clobert, J., Anderson, D. R. (1992) Modeling survival and testing biological hypotheses using marked animals: a unified approach with case-studies. Ecological Monographs 62, 67–118.
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.
Royle, J. A. (2004) N-mixture models for estimating population size from spatially replicated counts. Biometrics 60, 108–115.
Sugiura, N. (1978) Further analysis of the data by Akaike's information criterion and the finite corrections. Communications in Statistics: Theory and Methods A7, 13–26.
1 2 3 4 5 6 7 8 9 10 11 12 13
##cement data from Burnham and Anderson (2002, p. 101) data(cement) ##run multiple regression - the global model in Table 3.2 glob.mod <- lm(y ~ x1 + x2 + x3 + x4, data = cement) ##extract log-likelihood LL <- logLik(glob.mod) ##extract number of parameters K.mod <- coef(glob.mod) + 1 ##compute AICc with full likelihood AICcCustom(LL, K.mod, nobs = nrow(cement))
Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.