#74: Variance decomposition gives dummy results in the presence of non- stationary vars --------------------------+------------------------------------------------- Reporter: sebastien | Owner: Type: bug | Status: new Priority: major | Milestone: Component: Core M-files | Version: 4.1.0 Keywords: | --------------------------+------------------------------------------------- In the attached MOD file, the variance decomposition is clearly bogus: some lines don't sum to 100% (some percentages are even negative).
The problem does not occur with Dynare 4.0.4. This is probably related to the fact that this model contains a non-stationary variable. The file {{{th_autocovariances.m}}} has changed between versions 4.0.4 and 4.1.0 with respect to the treatment of stationary variables.
Also note that the problem does not come from the fact that some shocks are switched off (with a zero variance) in the attached MOD file. Activating all the shocks still gives dummy results.
#74: Variance decomposition gives dummy results in the presence of non- stationary vars ---------------------------+------------------------------------------------ Reporter: sebastien | Owner: michel Type: bug | Status: accepted Priority: major | Milestone: Component: Core M-files | Version: 4.1.0 Resolution: | Keywords: ---------------------------+------------------------------------------------ Changes (by michel):
* owner: => michel * status: new => accepted
Comment:
There is no unit root in this model. But BETAA = 1.001^-0.25 introduces a root of 1.0002 that Dynare treats correctly as > 1.0 Utility and Welfare in volume introduce very large values into the computations. It would be better to use their log as variables.
Dynare in branches/4.0 doesn't provide a correct decomposition either. (see the decomposition for sxp). In addition, one eigenvalue is reported as a NaN.
However, we shouldn't display variance decomposition for variables that don't have any variance and increase the (currently unused threshold on disp_th_moments.m line 44 of 1e-12).
For the denominator of the variance decomposition, we could consider cumulate the various contributions rather than using aggregate variance.
#74: Variance decomposition gives dummy results in the presence of non- stationary vars ---------------------------+------------------------------------------------ Reporter: sebastien | Owner: michel Type: bug | Status: closed Priority: major | Milestone: Component: Core M-files | Version: 4.1.0 Resolution: fixed | Keywords: ---------------------------+------------------------------------------------ Changes (by michel):
* status: accepted => closed * resolution: => fixed
Comment:
This model doesn't contain an exact unit root, but a root very close to zero. Some variances are therefore very large and in this case the sum of the effects of each shock is different from aggregate variance by a significant amount because of numerical error.
I now report variance decomposition relative to the sum of the effects of each shock rather than relative to aggregate variance. If the sum of the effects of each shocks is different from aggregate variance by more than 0.01 % a warning is displayed.
Fixed in commit c2f7f0a555882acd50cbb93b4c7c79603fac58ba and f76a657ceac93b488e0b242f9d30b20c0a9d5856 (4.1)