The cherrypick was failing if the selected equations were not about a PAC equation (e.g. a VAR expectation
model), because the code was assuming the existence of the pac field in M_.
The taget in PAC equation can be decomposed into an arbitrary number of components (variables
in the VAR auxiliary model).
TODO Iterative OLS estimation (which is not the preferred estimation routine).
TODO Decomposition in the routine evaluating the forecasts for each component.
This commit only introduce new elements in the Dynare language (adding the
possibility to decompose the target into stationary and non stationary
components) and insure that all the former codes (ie without decomposition of
the target) are still working as expected.
The correction for growth neutrality should be substituted in the optimal part
of the PAC equations.
(cherry picked from commit 12694ff9347b2191b4e0f6a32cb038956cb38f53)
- cherrypick routine was not returning the correct lists of endogenous
and exogenous variables. The number of endogenous variables was even
not matching the number of equations.
- In some cases LHS expressions were not preprocessed to extract the
name of an endogenous variable.
- Return a non cryptic error message if more than one endogenous
variable appears in the LHS.
DO not print files for parameters declaration, exogenous variables declarations
or parameter values if the selected equations do not have parameters and/or
exogenous variables (typically accounting identities).
Renamed the auxiliary variables for PAC/VAR expectations unrolled
expressions. Using shorter prefixes, PE_ and VE_ instead of pac_expectation and
var_expectations.
Extracts equations from a mod file and produce .inc files (equations, lists of
parameters, endogenous variables and exogenous variables) that can be included
in a mod file that will be used to simulate the model.
If an innovation has a tag `(used='estimationonly')` it will be excluded from
the generated files (ie list of shocks and equations).