Commit Graph

2944 Commits (4.7)

Author SHA1 Message Date
Sébastien Villemot c63d08007c
Fix error message when using pac_expectation with occbin_constraints
By the way, also fix the argument name (the model is not a VAR).

(cherry picked from commit 0123326123)
2021-10-29 14:12:13 +02:00
Sébastien Villemot ff564cbc9a
PAC: add growth correction term for definition of Z₁ in the MCE case
(cherry picked from commit 5bef185370)
2021-10-25 19:18:36 +02:00
Sébastien Villemot d430f47616
Improve message for GCC installation under macOS
(cherry picked from commit 8bb8e59410)
2021-10-08 15:51:37 +02:00
Sébastien Villemot 990cee70c2
PAC: better error message in case of name conflict for the growth neutrality correction parameter
(cherry picked from commit 78e295115a)
2021-10-06 16:42:22 +02:00
Johannes Pfeifer dfed3e98ab
ramsey_model: Fix error message logic
one of the statements being present is sufficient

(cherry picked from commit b496c4ba2c)
2021-09-24 16:54:28 +02:00
Sébastien Villemot 784b2d6d40
Remove unused steady_state_growth option to pac_model
(cherry picked from commit eb006ecaeb)
2021-09-22 17:29:53 +02:00
Johannes Pfeifer 0ccb986da8
Rename mh_mode to correct mh_posterior_mode_estimation option
Closes https://git.dynare.org/Dynare/preprocessor/-/issues/60

(cherry picked from commit 8d14e18cdb)
2021-09-22 17:28:32 +02:00
Sébastien Villemot d03b74469a
ramsey_{model,policy}, discretionary_policy: check that instruments are declared endogenous
Closes: #72
(cherry picked from commit b12746190d)
2021-09-21 18:41:41 +02:00
Sébastien Villemot 37b38b46cc
Fix use_dll on macOS + Octave
Enforce GCC with mkoctfile. Otherwise Clang will be used, and it does not
accept our custom optimization flags.

Ref. dynare#1797

(cherry picked from commit 3d215020ae)
2021-09-13 16:52:27 +02:00
Sébastien Villemot b1a0ebf513
Fix bug introduced in previous commit that triggers a crash for DSGE-VAR models
(cherry picked from commit 989347f448)
2021-09-08 19:00:58 +02:00
Sébastien Villemot 79efd2ec17
estimated_params*: add a check that prevents (apparently) recursive prior definitions
Closes: #77
(cherry picked from commit cb19ece049)
2021-09-08 17:11:48 +02:00
Sébastien Villemot 04e42fa821
estimated_params_{bounds,init} now check that a parameter (or correlation) is never declared twice
This check was previously only implemented in estimated_params.

(cherry picked from commit 62ba9a434a)
2021-09-08 17:11:47 +02:00
Sébastien Villemot ce43e91b57
PAC: generate the “growth_neutrality_param_index” MATLAB field for MCE models
Previously it was only generated in the case of backward PAC models.

(cherry picked from commit 784dd4122a)
2021-09-01 11:31:08 +02:00
Sébastien Villemot d528467234
Ensure that the “discount” option of “pac_model” is a parameter
Ref. Madysson/estimation-codes#4

(cherry picked from commit 6863494db2)
2021-08-31 13:58:59 +02:00
Johannes Pfeifer 4f8713134f
method_of_moments: move to namespace
(cherry picked from commit 3f37d9692c)
2021-08-31 13:56:19 +02:00
Stéphane Adjemian (Charybdis) 2f2e02e007
Fix warning (missing option in occbin_setup).
(cherry picked from commit 79d5a2d687)
2021-08-18 15:29:06 +02:00
Stéphane Adjemian 0bbba398a1
Merge branch 'occbin_options' into 'master'
Occbin: Add missing options

See merge request Dynare/preprocessor!49
2021-08-16 12:09:37 +02:00
Sébastien Villemot 0a6b71a375
Bump version number 2021-07-23 15:40:27 +02:00
Sébastien Villemot bb19d98712 Merge branch 'results_file' into 'master'
Move results file to output folder

See merge request Dynare/preprocessor!48
2021-07-23 11:58:46 +00:00
Johannes Pfeifer 361b789e88 Move results file to output folder 2021-07-22 19:36:12 +02:00
Sébastien Villemot 5cfe6303e2
Cosmetic changes 2021-07-22 16:49:59 +02:00
Sébastien Villemot 30972e44ef Merge branch 'smoother2histval' into 'master'
Introduce option consider_all_endogenous_and_auxiliary

See merge request Dynare/preprocessor!46
2021-07-22 10:21:03 +00:00
Johannes Pfeifer 5da01faa74 Introduce option consider_all_endogenous_and_auxiliary 2021-07-22 11:49:36 +02:00
Sébastien Villemot 2fc8b71ac6
CI: bump Julia and Boost/Windows versions 2021-07-21 20:16:19 +02:00
Sébastien Villemot e1f7d8c735
VAR models: add a parameter representing the constant in the development of the pac_expectation operator 2021-07-21 17:53:55 +02:00
Sébastien Villemot da9e0acc2d
VAR models: add a parameter representing the constant in the development of the var_expectation operator 2021-07-21 17:53:55 +02:00
Sébastien Villemot 1a5fb4d5e6
DynamicModel: make PAC data members private 2021-07-21 17:53:55 +02:00
Stéphane Adjemian (Ryûk) 8305b94d29
Fix constant definition in reduced form VAR. 2021-07-21 17:53:55 +02:00
Stéphane Adjemian (Ryûk) c6a7d56b36
Fix constants in var model (it has to be a vector). 2021-07-21 17:53:55 +02:00
Sébastien Villemot a6add6127b
VAR models: output vector of constants in varmatrices.m 2021-07-21 17:53:54 +02:00
Sébastien Villemot 1cf03a5f07
Cosmetic improvement 2021-07-21 17:53:54 +02:00
Sébastien Villemot 5498ce98ee
Use NumConstNode* type for DataTree constants (previously they were just expr_t) 2021-07-21 17:53:54 +02:00
Sébastien Villemot 15d7432105
Occbin: add more sanity checks on expressions in “occbin_constraints” block
— forbid leads and lags
— forbid expectation operators

This is implemented by moving the occbin_constraints expression to a separate
DataTree. As a side-effect, this removes the spurious non-linearity warning in
a stochastic context (because we were introducing inequalities and abs()
operators in the main DynamicModel tree).
2021-07-21 16:33:23 +02:00
Sébastien Villemot ed31d1cb5e
Remove unused functions 2021-07-21 16:33:23 +02:00
Sébastien Villemot 6ae3d3131f
Occbin: handle external functions in “occbin_constraints” 2021-07-21 16:33:19 +02:00
Sébastien Villemot 0d6eb053d4
Ensure that “pac_expectation” operators are never inserted into a static model
The implementation of PacExpectationNode::toStatic() did not make sense. It
should normally never be called, hence we error out at this point.

Also do a cosmetic change in the PacExpectationNode::clone() methode.
2021-07-21 16:33:14 +02:00
Sébastien Villemot b16ab9b247
Fix preprocessor crash when a [static] equation contains a “var_expectation” operator
Rather error out with a meaningful message.
2021-07-21 16:33:09 +02:00
Sébastien Villemot ebd9954d33
Occbin: new syntax for constructing multi-regime equations
Ref. #68
2021-07-20 18:18:24 +02:00
Sébastien Villemot 0b8e3345fc
Ensure that a tag is not declared twice in the same equation
Previously the first value was silently ignored. It’s better to explicitly
forbid this. If this change creates problems (since it’s a change in an
undocumented behaviour), we can turn it into a warning.
2021-07-20 14:56:48 +02:00
Sébastien Villemot 81d4fd5d83
Occbin: generate +<basename>/occbin_difference.m
In particular, this implies that steady state values of endogenous in the
“occbin_constraints” block must now be specified using the STEADY_STATE()
operator (and not with a “_ss” suffix).

Moreover:
– make various simplifications to the fields generated under M_
– in the driver file, replace the call to occbin.initialize() by a few explicit operations

Ref. #68
2021-07-20 12:26:11 +02:00
Sébastien Villemot 90b1235a64
New utility to check if an expression contains an exogenous (possibly deterministic) 2021-07-20 12:10:58 +02:00
Sébastien Villemot 08ac455fcd
Implement “occbin_constraints” block
Consequently drop “occbin” option to “model”.

Incidentally, allow more values in equation tag names (previously some keywords
such as “alpha” were disallowed).

Ref. #68
2021-07-16 11:34:27 +02:00
Stéphane Adjemian (Ryûk) 6b9d94405c
Return the reduced form of the structural VAR model optionally.
Also

 - changed the name of the generated matlab routine,
 - changed initialization of matrix a0.
2021-07-16 08:33:26 +02:00
Sébastien Villemot 2e696a2e0d
Add shocks(surprise) block (for occbin)
Ref. #68
2021-07-13 21:55:31 +02:00
Sébastien Villemot f0002c5ac6
Fix compiler warning introduced by 61b37942ab 2021-07-13 17:18:06 +02:00
Sébastien Villemot c3b0ce8e69
shocks/mshocks/conditional_forecast_paths: various cleanups 2021-07-13 17:17:57 +02:00
Sébastien Villemot 5624260a07 Merge branch 'occbin_rebase' into 'master'
First part of Occbin interface

See merge request Dynare/preprocessor!42
2021-07-13 13:38:26 +00:00
Johannes Pfeifer 61b37942ab First part of Occbin interface 2021-07-13 13:38:25 +00:00
Sébastien Villemot c9c36c037a
New preprocessor option “nocommutativity”
This option tells the preprocessor not to use the commutativity of addition and
multiplication when looking for common subexpressions.

As a consequence, when using this option, equations in various outputs (LaTeX,
JSON…) will appear as the user entered them.

There is however a potential performance cost to using this option, yet to be
determined.

Ref. dynare#1788
2021-07-13 14:35:10 +02:00
Sébastien Villemot 6aeef11bb2
New perfect_foresight_with_expectation_errors_{setup,solver} commands 2021-07-09 17:14:22 +02:00