Proposed specification for estimation functions

This includes factorization of common code and extensions for (unexpected) structural change

Estimated parameters description

xparam1 is a column n by 1 vector holding the current values of the estimated parameters (n is the number of parameters).

parameters_description is a (global?) strucure of arrays describing the estimated parameters with the following fields:

Remark 1. The considered subsamples for different parameters may be different.

Remark 2. StartPeriod and EndPeriod specify the closed sub sample used to estimate the parameter. If these two fields are empty the parameter is estimated using the whole sample.

Remark 3. The field Prior is empty if the model is estimated by maximum lilkelihood, simulated moments or indirect inference.

Remark 4. xxx_id vectors select subset of xparam1 (for instance, xparam_1(np_id) selects all the lines of xparam1 corresponding to the estimated "deep" parameters).

Functions