# AIC.dfunc: AICc and related fit statistics for detection function... In Rdistance: Distance-Sampling Analyses for Density and Abundance Estimation

## Description

Computes AICc, AIC, or BIC for estimated distance functions.

## Usage

 ```1 2``` ```## S3 method for class 'dfunc' AIC(object, ..., criterion = "AICc") ```

## Arguments

 `object` An estimated detection function object. An estimated detection function object has class 'dfunc', and is usually produced by a call to `dfuncEstim`. `...` Required for compatibility with the general `AIC` method. Any extra arguments to this function are ignored. `criterion` String specifying the criterion to compute. Either "AICc", "AIC", or "BIC".

## Details

Regular Akaike's information criterion (http://en.wikipedia.org/wiki/Akaike_information_criterion) (AIC) is

AIC = (LL) + 2p,

where LL is the maximized value of the log likelihood (the minimized value of the negative log likelihood) and p is the number of coefficients estimated in the detection function. For `dfunc` objects, AIC = `obj\$loglik + 2*length(coef(obj))`.

A correction for small sample size, AICc, is

AIC_c = LL + 2p + (2p(p+1))/(n-p-1),

where n is sample size or number of detected groups for distance analyses. By default, this function computes AICc. AICc converges quickly to AIC as n increases.

The Bayesian Information Criterion (BIC) is

BIC = (LL) + log(n)p

.

## Value

A scalar. By default, the value of AICc for the estimated distance function `obj`.

## Author(s)

Trent McDonald, WEST Inc., tmcdonald@west-inc.com

## References

Burnham, K. P., and D. R. Anderson, 2002. Model selection and multi-model inference: A practical information-theoretic approach, Second ed. Springer-Verlag. ISBN 0-387-95364-7.

McQuarrie, A. D. R., and Tsai, C.-L., 1998. Regression and time series model selection. World Scientific. ISBN 981023242X

`coef`, `dfuncEstim`
 ``` 1 2 3 4 5 6 7 8 9 10 11 12``` ```# Load the example dataset of sparrow detections from package data(sparrowDetectionData) # Fit detection function to perpendicular, off-transect distances dfunc <- dfuncEstim(dist~1, detectionData=sparrowDetectionData, w.hi=150) # Compute fit statistics AIC(dfunc) # AICc AIC(dfunc, criterion="AIC") # AIC AIC(dfunc, criterion="BIC") # BIC ```