Main Content

aic

Akaike’s Information Criterion for estimated model

Description

value = aic(model) returns the normalized Akaike's Information Criterion (AIC) value for the estimated model.

example

value = aic(model1,...,modeln) returns the normalized AIC values for multiple estimated models.

value = aic(___,measure) specifies the type of AIC.

example

Examples

collapse all

Estimate a transfer function model.

load iddata1 z1;
np = 2;
sys = tfest(z1,np);

Compute the normalized Akaike's Information Criterion value.

value = aic(sys)
value = 
0.5453

The value is also computed during model estimation. Alternatively, use the Report property of the model to access this value.

sys.Report.Fit.nAIC
ans = 
0.5453

Estimate a transfer function model.

load iddata1 z1;
np = 2;
sys = tfest(z1,np);

Compute the normalized Akaike's Information Criterion (AIC) value. This syntax is equivalent to aic_raw = aic(sys).

aic_raw = aic(sys,'nAIC')
aic_raw = 
0.5453

Compute the raw AIC value.

aic_raw = aic(sys,'aic')
aic_raw = 
1.0150e+03

Compute the sample-size corrected AIC value.

aic_c = aic(sys,'AICc')
aic_c = 
1.0153e+03

Compute the Bayesian Information Criteria (BIC) value.

bic = aic(sys,'BIC')
bic = 
1.0372e+03

These values are also computed during model estimation. Alternatively, use the Report.Fit property of the model to access these values.

sys.Report.Fit
ans = struct with fields:
    FitPercent: 70.7720
       LossFcn: 1.6575
           MSE: 1.6575
           FPE: 1.7252
           AIC: 1.0150e+03
          AICc: 1.0153e+03
          nAIC: 0.5453
           BIC: 1.0372e+03

Estimate multiple Output-Error (OE) models and use the small sample-size corrected Akaike's Information Criterion (AICc) value to pick the one with optimal tradeoff between accuracy and complexity.

Load the estimation data.

load iddata2

Specify model orders varying in 1:4 range.

nf = 1:4;
nb = 1:4;
nk = 0:4;

Estimate OE models with all possible combinations of chosen order ranges.

NN = struc(nf,nb,nk); 
models = cell(size(NN,1),1);
for ct = 1:size(NN,1)
   models{ct} = oe(z2, NN(ct,:));
end

Compute the small sample-size corrected AIC values for the models, and return the smallest value.

V = aic(models{:},'AICc');
[Vmin,I] = min(V);

Return the optimal model that has the smallest AICc value.

models{I}
ans =
Discrete-time OE model: y(t) = [B(z)/F(z)]u(t) + e(t)
  B(z) = 1.067 z^-2                                  
                                                     
  F(z) = 1 - 1.824 z^-1 + 1.195 z^-2 - 0.2307 z^-3   
                                                     
Sample time: 0.1 seconds
  
Parameterization:
   Polynomial orders:   nb=1   nf=3   nk=2
   Number of free coefficients: 4
   Use "polydata", "getpvec", "getcov" for parameters and their uncertainties.

Status:                                     
Estimated using OE on time domain data "z2".
Fit to estimation data: 86.53%              
FPE: 0.9809, MSE: 0.9615                    
 
Model Properties

Input Arguments

collapse all

Identified model, specified as one of the following model objects:

Type of AIC, specified as one of the following values:

  • 'nAIC' — Normalized AIC

  • 'aic' — Raw AIC

  • 'AICc' — Small sample-size corrected AIC

  • 'BIC' — Bayesian Information Criteria

See Akaike's Information Criterion (AIC) for more information.

Output Arguments

collapse all

Value of the quality measure, returned as a scalar or vector. For multiple models, value is a row vector where value(k) corresponds to the kth estimated model modelk.

More About

collapse all

Tips

  • The software computes and stores all types of Akaike's Information Criterion metrics during model estimation. If you want to access these values, see the Report.Fit property of the model.

References

[1] Ljung, L. System Identification: Theory for the User, Upper Saddle River, NJ, Prentice-Hall PTR, 1999. See sections about the statistical framework for parameter estimation and maximum likelihood method and comparing model structures.

Version History

Introduced before R2006a