# aic

## PURPOSE

## SYNOPSIS

function g=aic(varargin)

## DESCRIPTION

## CROSS-REFERENCE INFORMATION

This function calls:

- locfit Smoothing noisy data using Local Regression and Likelihood.
- rsum

This function is called by:

- aicplot

## SOURCE CODE

    0001 function g=aic(varargin)
    0002
    0003 pen = 2.0;
    0004
    0005 fit = locfit(varargin{:});
    0006 rs = rsum(fit);
    0007
    0008 df0 = rs(1);
    0009 df1 = rs(2);
    0010 llk = rs(3);
    0011 ai = -2*llk + pen * df0;
    0012 g = [llk df0 df1 ai];
    0013
    0014 return;