function opt = impulseestOptions(varargin)
%IMPULSEESTOPTIONS Creates option set for the IMPULSEEST command.
%
%   OPT = IMPULSEESTOPTIONS returns the default options for IMPULSEEST. The
%   supported options are:
%
%   PW            Order of the input prewhitening filter. Specify as a
%                 nonnegative integer or the string "auto". Default is
%                 "auto", which implies a filter of order 10 when no
%                 regularization is used and 0 when regularization is used.
%                 Use RegularizationKernel option to specify regularization kernel. 
%
%   EstimateCovariance  Specify whether to estimate parameter covariance (true)
%                       or not (false). Default: true.
%
%   RegularizationKernel   Kernel used for regularization. 
%                 One of: 'none', 'TC', 'SE', 'SS','HF', 'DI', 'DC'. 
%                  'none': no regularization is used 
%                    'TC': tuned and correlated kernel (default) 
%                    'SE': squared exponential kernel
%                    'SS': stable spline kernel
%                    'HF': high frequency stable spline kernel
%                    'DI': diagonal kernel
%                    'DC': diagonal and correlated kernel
%                 The specified kernel is used for estimation of impulse
%                 response for all input-output channels. For more
%                 information see [1].
%
%   InputOffset   Specifies the offset levels present in the input signals
%                 of the estimation data. Specify as an Nu-element column
%                 vector, where Nu is the number of inputs. For estimations
%                 using multi-experiment data, specify as Nu-by-Ne matrix,
%                 where Ne is the number of experiments. The offset value
%                 InputOffset(i,j) is subtracted from the i:th input signal
%                 of the j:th experiment. Default is [] which implies no
%                 offsets. Available for estimations using time-domain data
%                 only.
%
%   OutputOffset  Specifies the output signal offset levels. Similar
%                 interpretation as InputOffset. The specified values are
%                 subtracted from the output signals before using them for
%                 estimation.
%
%   Advanced      Structure with fields MaxSize, SearchMethod, AROrder and
%                 FeedthroughInSys. Apply for regularized estimation only. 
%                 MaxSize: Maximum allowable size of Jacobian matrices
%                          formed during estimation. Specify as a large
%                          positive number. Default: 250e3. 
%                 SearchMethod: Choice of search method for estimation of
%                          regularization parameters. Applicable values
%                          are:
%                          'gn'      - Quasi-Newton line search.
%                          'fmincon' - Trust region reflective constrained
%                                      minimizer. Default.  
%                 AROrder: The order of AR-part in the model from input
%                          to output. An order>0 allows more accurate
%                          models of the impulse response in case of
%                          feedback and non-white output disturbances.
%                          Specify as a positive integer. Default: 5.
%                 FeedthroughInSys: specify whether impulse response value
%                          at zero lag must be attributed to feedthrough in
%                          system (TRUE) or to feedback effects (FALSE).
%                          Applies only when response values for negative
%                          lags are requested. Default: FALSE.
%
% Reference:
%  [1] On the Estimation of Transfer Functions, Regularizations and
%  Gaussian Processes - Revisited, Chen, Tianshi, Ohlsson, Henrik, Ljung,
%  Lennart. Automatica, Volume 48,  August 2012.
%
%  See also IMPULSEEST.

%   Author(s): Rajiv Singh
%   Copyright 2012-2017 The MathWorks, Inc.
try
   opt = initOptions(idoptions.impulseest,varargin);
catch E
   throw(E);
end
