Documentation Center

  • Trial Software
  • Product Updates

compareOptions

Option set for compare

Syntax

opt = compareOptions
opt = compareOptions(Name,Value)

Description

opt = compareOptions creates the default options set for compare.

opt = compareOptions(Name,Value) creates an option set with the options specified by one or more Name,Value pair arguments.

Input Arguments

Name-Value Pair Arguments

Specify optional comma-separated pairs of Name,Value arguments. Name is the argument name and Value is the corresponding value. Name must appear inside single quotes (' '). You can specify several name and value pair arguments in any order as Name1,Value1,...,NameN,ValueN.

'Samples'

Data for which compare calculates fit values.

Specify Samples as a vector containing the data sample indices. For multiexperiment data, use a cell array of Ne vectors, where Ne is the number of experiments.

'InitialCondition'

Specify how initial conditions are handled.

InitialCondition requires one of the following values:

  • 'z' — Zero initial conditions.

  • 'e' — Estimate initial conditions such that the prediction error for observed output is minimized.

  • 'd' — Similar to 'e', but absorbs nonzero delays into the model coefficients. Use this option for discrete-time models only.

  • x0 — Numerical column vector denoting initial states. For multiexperiment data, use a matrix with Ne columns, where Ne is the number of experiments. Use this option for state-space models only.

  • io — Structure with the following fields:

    • Input

    • Output

    Use the Input and Output fields to specify the input/output history for a time interval that starts before the start time of the data used by compare. If the data used by compare is a time-series model, specify Input as []. Use a row vector to denote a constant signal value. The number of columns in Input and Output must always equal the number of input and output channels, respectively. For multiexperiment data, specify io as a struct array of Ne elements, where Ne is the number of experiments.

  • x0obj — Specification object created using idpar. Use this object for discrete-time state-space models only (idss, idgrey) . Use x0obj to impose constraints on the initial states by fixing their value or specifying minimum/maximum bounds.

Default: 'e'

'InputOffset'

Removes offset from time domain input data for model response computation.

Specify as a column vector of length Nu, where Nu is the number of inputs.

Use [] to indicate no offset.

For multiexperiment data, specify InputOffset as a Nu-by-Ne matrix. Nu is the number of inputs and Ne is the number of experiments.

Each entry specified by InputOffset is subtracted from the corresponding input data.

Default: []

'OutputOffset'

Removes offset from time domain output data for model response prediction.

Specify as a column vector of length Ny, where Ny is the number of outputs.

Use [] to indicate no offset.

For multiexperiment data, specify OutputOffset as a Ny-by-Ne matrix. Ny is the number of outputs and Ne is the number of experiments.

Each entry specified by OutputOffset is subtracted from the corresponding output data.

Default: []

'OutputWeight'

Weight of output for initial condition estimation.

OutputWeight requires one of the following values:

  • [] — No weighting is used. This option is the same as using eye(Ny) for the output weight. Ny is the number of outputs.

  • 'noise' — Inverse of the noise variance stored with the model.

  • Matrix of doubles — A positive semi-definite matrix of dimension Ny-by-Ny. Ny is the number of outputs.

Default: []

Output Arguments

opt

Option set containing the specified options for compare.

Examples

expand all

Create Default Options Set for Model Comparison

Create a default options set for compare.

opt = compareOptions;

Specify Options for Model Comparison

Create an options set for compare using zero initial conditions. Set the input offset to 5.

opt = compareOptions('InitialCondition','z','InputOffset',5);

Alternatively, use dot notation to set the values of opt.

opt = compareOptions;
opt.InitialCondition = 'z';
opt.InputOffset = 5;

See Also

Was this topic helpful?