dynare issueshttps://git.dynare.org/Dynare/dynare/-/issues2023-09-07T14:56:43Zhttps://git.dynare.org/Dynare/dynare/-/issues/1903Disentangle functions of diffuse_filter2023-09-07T14:56:43ZJohannes PfeiferDisentangle functions of diffuse_filterThe `diffuse_filter`-option serves three purposes:
1. setting `qz_criterium`
2. setting `lik_init`
3. setting `kalman_algo`
This creates unintended consequences.
1. In principle, we don't need `diffuse_filter` if the observables are st...The `diffuse_filter`-option serves three purposes:
1. setting `qz_criterium`
2. setting `lik_init`
3. setting `kalman_algo`
This creates unintended consequences.
1. In principle, we don't need `diffuse_filter` if the observables are stationary (`diffuse_periods=0`). But `diffuse_filter` is still required to change the setting of `qz_criterium` and set `lik_init`. That seems problematic.
2. Specifying `diffuse_filter` is incompatible with `fast_kalman_filter`, but that will not trigger a warning and will work if `diffuse_periods=0`. But it should be slower due to solving the Lyapunov equation differently.https://git.dynare.org/Dynare/dynare/-/issues/1902Allow looping over (random) starting values for estimation2023-09-07T08:46:24ZJohannes PfeiferAllow looping over (random) starting values for estimationRequest at advanced user meeting: draw from prior and start mode-finding.Request at advanced user meeting: draw from prior and start mode-finding.https://git.dynare.org/Dynare/dynare/-/issues/1901Improve convergence diagnostics2023-09-07T08:31:51ZJohannes PfeiferImprove convergence diagnostics1. Multivariate instead of univariate diagnostics https://academic.oup.com/biomet/article-abstract/106/2/321/5426969?redirectedFrom=fulltext and https://doi.org/10.1214/20-STS812
2. Have quantitative instead of eyeballing test for multi...1. Multivariate instead of univariate diagnostics https://academic.oup.com/biomet/article-abstract/106/2/321/5426969?redirectedFrom=fulltext and https://doi.org/10.1214/20-STS812
2. Have quantitative instead of eyeballing test for multiple chains.https://git.dynare.org/Dynare/dynare/-/issues/1869Allow "globally" setting OccBin options for all sub-routines2023-09-06T12:38:41ZJohannes PfeiferAllow "globally" setting OccBin options for all sub-routinesFor options that can be set for the various cases (likelihood, smoother, simul), implement a way to set all sub-cases in `occbin_setup` by using one option. (See https://git.dynare.org/Dynare/dynare/-/merge_requests/2094#note_17648)
Prop...For options that can be set for the various cases (likelihood, smoother, simul), implement a way to set all sub-cases in `occbin_setup` by using one option. (See https://git.dynare.org/Dynare/dynare/-/merge_requests/2094#note_17648)
Proposal: e.g. `check_ahead` as a stand-in for `*_check_ahead`https://git.dynare.org/Dynare/dynare/-/issues/1880Missing input sanitization in parallel configuration file2023-09-06T10:54:55ZSébastien VillemotMissing input sanitization in parallel configuration fileInput read from the parallel configuration file, specifically from the `UserName`, `ComputerName`, and `RemoteDirectory` fields, is passed directly to a `system` call without any sanitization.
Command injection example with the `UserNam...Input read from the parallel configuration file, specifically from the `UserName`, `ComputerName`, and `RemoteDirectory` fields, is passed directly to a `system` call without any sanitization.
Command injection example with the `UserName` field:
```
[cluster]
Name = LocalProfile1
Members = n1
[node]
Name = n1
ComputerName = 192.168.1.62
CPUnbr = 8
NumberOfThreadsPerJob = 1
OperatingSystem = unix
RemoteDirectory = test
UserName = & ping 127.0.0.1 &
Password = test
```
Intigriti submission reference: `DYNARE-4CN0UV5J`https://git.dynare.org/Dynare/dynare/-/issues/1899Document of fix behavior of det_cond_forecast2023-08-30T18:18:30ZJohannes PfeiferDocument of fix behavior of det_cond_forecastFrom https://forum.dynare.org/t/error-messages-when-building-the-forecast/22873/4.
I think there is either a bug or the manual is wrong. `det_cond_forecast` seems to always expect three input arguments, i.e. the initial forecast date is...From https://forum.dynare.org/t/error-messages-when-building-the-forecast/22873/4.
I think there is either a bug or the manual is wrong. `det_cond_forecast` seems to always expect three input arguments, i.e. the initial forecast date is mandatory.
[IN_AUX.csv](/uploads/ed7b4b47377fb38a92a99c7b0c571549/IN_AUX.csv)
[UForecast.mod](/uploads/e9d55faa83615f4f0040c5bbb45e2d41/UForecast.mod)
Moreover, the second argument is supposed to indicate the past values of the endogenous variables. But using [UForecast_3_arguments.mod](/uploads/bf27cd7ac32670a1a9b5a09b9184e493/UForecast_3_arguments.mod) I get the error message
> the dseries smoothed finish at time 2023Q2 before the last period of forecast 2024Q3
which does not make sense if only past values are needed.https://git.dynare.org/Dynare/dynare/-/issues/1896Discuss detrending of lagged trend_var2023-07-28T08:06:08ZJohannes PfeiferDiscuss detrending of lagged trend_varConsider
```
var gd, gu;
trend_var(growth_factor=gu) Bu;
trend_var(growth_factor=gd) Bd;
varexo vd,vu;
parameters gamu,gamd,thetadu;
gamu=.01;
gamd=.003;
thetadu=0.3;
model;
log(gu)=log(1+gamu)+vu;
log(gd)=log(1+gamd)+thetadu*l...Consider
```
var gd, gu;
trend_var(growth_factor=gu) Bu;
trend_var(growth_factor=gd) Bd;
varexo vd,vu;
parameters gamu,gamd,thetadu;
gamu=.01;
gamd=.003;
thetadu=0.3;
model;
log(gu)=log(1+gamu)+vu;
log(gd)=log(1+gamd)+thetadu*log(Bu(-1)/Bd(-1))+thetadu*log((1+gamu)/(1+gamd))+vd;
end;
initval;
gu=1.01;
gd=1.003;
vd = 0; vu=0;
end;
steady;
check;
shocks;
var vd; stderr 0.02;
var vu; stderr 0.02;
end;
write_latex_dynamic_model;
collect_latex_files;
stoch_simul(irf=150,order=1) gu gd;
```
from https://forum.dynare.org/t/impulse-responses-with-cointegrated-stochastic-trends/22756
Internally, we replace the lagged `trend_var Bu`, i.e. `Bu(-1)`, by its definition `Bu/gu`. The problem is that we then use the normalization `Bu=1`, i.e. we fix today's value of the trend and have `gu` implicitly determine the predetermined value yesterday. As a consequence, the variable `gd` on the left suddenly reacts contemporaneously to `gu`, although in the original equation everything on the right was predetermined. My understanding is that for a stochastic `growth_factor` this detrending approach is problematic as we are violating predeterminedness. What is the solution to this issue? Normalizing an endogenous object at time $t$ to 1 seems to be poor practice. At a minimum, we need to document the current behavior.https://git.dynare.org/Dynare/dynare/-/issues/832Use dseries objects in Dynare2023-06-13T13:21:45ZStéphane Adjemianstepan@adjemian.euUse dseries objects in DynareIn the current state, `dseries` objects can be used in matlab scripts and in Dynare's mod file to create and manipulate datasets. The next step is to integrate more deeply the `dseries` class and Dynare. Whenever possible the output of D...In the current state, `dseries` objects can be used in matlab scripts and in Dynare's mod file to create and manipulate datasets. The next step is to integrate more deeply the `dseries` class and Dynare. Whenever possible the output of Dynare will be `dseries` objects (IRFs, forecasts, ...) and also we will allow the use of `dseries` objects as inputs to Dynare's command (`data`, content of `initval`, data for conditional forecasts, ...).
- [ ] Document the `data` command (new data interface).
- [ ] Save results as `dseries` objects.
- [x] Polish and document the from-to-do syntax.
- [ ] Add the possibility to pass `dseries`to `initial``and``histval``commands.
Stéphane Adjemianstepan@adjemian.euStéphane Adjemianstepan@adjemian.euhttps://git.dynare.org/Dynare/dynare/-/issues/7In dr.tex, add a concrete example on a model (by expliciting the matrices)2023-06-06T07:56:02ZSébastien VillemotIn dr.tex, add a concrete example on a model (by expliciting the matrices)https://git.dynare.org/Dynare/dynare/-/issues/300Implement k-order derivatives of external functions2023-02-24T21:55:57ZSébastien VillemotImplement k-order derivatives of external functionsOtherwise order ≥ 3 fails with a cryptic preprocessor errorOtherwise order ≥ 3 fails with a cryptic preprocessor errorhttps://git.dynare.org/Dynare/dynare/-/issues/1876Document behavior of steady_state()-operator with trending variables2022-12-20T16:37:03ZJohannes PfeiferDocument behavior of steady_state()-operator with trending variablesSee https://forum.dynare.org/t/correct-specification-of-fiscal-rules-in-a-non-stationary-environment/21245/4See https://forum.dynare.org/t/correct-specification-of-fiscal-rules-in-a-non-stationary-environment/21245/4Johannes PfeiferJohannes Pfeiferhttps://git.dynare.org/Dynare/dynare/-/issues/614Have balanced growth test consider steady_state_model-block2022-12-09T13:31:48ZMichelJuillardHave balanced growth test consider steady_state_model-blockHere is an example where an error in trend declaration isn't detected by the balanced growth test. It may come from the fact that labor enhancing productivity (G) is not a variable of the model, just a trend. The error should appear for ...Here is an example where an error in trend declaration isn't detected by the balanced growth test. It may come from the fact that labor enhancing productivity (G) is not a variable of the model, just a trend. The error should appear for the equations defining r and w and for the resource constraint.
```
parameters rho delta gamma alpha lambda g;
trend_var(growth_factor=1+g) G;
// the trend of K is wrong:
var(deflator=G) C w;
var L r A K;
// Here is the correct specification:
// var(deflator=G) C w K;
// var L r A;
varexo e;
alpha = 0.33;
delta = 0.1;
rho = 0.03;
lambda = 0.97;
gamma = 0;
g = 0.015;
model;
1/C = 1/(1+rho)*(1/C(+1))*(r(+1)+1-delta);
L^gamma = w/C;
r = alpha*A*K(-1)^(alpha-1)*(G*L)^(1-alpha);
w = (1-alpha)*A*K(-1)^alpha*(G*L)^(-alpha);
K+C = K(-1)*(1-delta)+A*K(-1)^alpha*(G*L)^(1-alpha);
log(A) = lambda*log(A(-1))+e;
end;
steady_state_model;
A = 1;
r = (1+g)*(1+rho)+delta-1;
K_L = (1+g)*(r/(alpha*A))^(1/(alpha-1));
w = (1-alpha)*A*(K_L/(1+g))^alpha;
L = (-((delta+g)/(1+g))*K_L/w+A*(K_L/((1+g)*w^(1/alpha)))^alpha)
^(-1/(1+gamma));
K = K_L*L;
C = (1-delta)*K/(1+g)+(K_L/(1+g))^alpha*L-K;
end;
shocks;
var e; stderr 0.01;
end;
write_latex_dynamic_model;
steady;
check;
stoch_simul(order=1);
```https://git.dynare.org/Dynare/dynare/-/issues/1868Calculation of possible simulation dates and determination of which variables...2022-11-08T15:41:08ZPierre AldamaCalculation of possible simulation dates and determination of which variables limit the datesIn large-scale semi-structural models, the number of endogenous and exogenous variables sometimes can be really large (generally hundreds). As a consequence, users can have hard-time to find which are the possible simulation dates (earli...In large-scale semi-structural models, the number of endogenous and exogenous variables sometimes can be really large (generally hundreds). As a consequence, users can have hard-time to find which are the possible simulation dates (earliest and latest start-date but also latest end-date), which depend on hundreds of endogenous and exogenous variables.
A solution would be to develop a function with two inputs: a model and a dseries containing all endogenous and exogenous variables, and finally returns 3 informations:
- earliest possible simulation start-date
- latest possible simulation start-date
- latest possible simulation end-date
with a list of limiting variables for each date.
In order to derive these dates, based on the dseries and on the model, the algorithm would use: i) the first and last common dates of observed endogenous variables; ii) the last common date of observed exogenous variables and iii) the maximum number of lags and leads in the model.https://git.dynare.org/Dynare/dynare/-/issues/1867Rework perfect foresight handling of initial and terminal values2022-10-13T10:12:25ZJohannes PfeiferRework perfect foresight handling of initial and terminal values1. Disentangle the purpose of various blocks (see https://archives.dynare.org/DynareWiki/DeterministicSimulationBlocks)
2. Eliminate reuse of `oo_.steady_state` for different purposes.
3. Phase out the global variables `ex0_` and `ys0_...1. Disentangle the purpose of various blocks (see https://archives.dynare.org/DynareWiki/DeterministicSimulationBlocks)
2. Eliminate reuse of `oo_.steady_state` for different purposes.
3. Phase out the global variables `ex0_` and `ys0_` used in `make_ex_` and `make_y_`
Related to https://git.dynare.org/Dynare/preprocessor/-/issues/104 and https://git.dynare.org/Dynare/dynare/-/issues/1866https://git.dynare.org/Dynare/dynare/-/issues/1843Fix stochastic singularity check with `heteroskedastic_shocks`2022-09-21T08:29:57ZJohannes PfeiferFix stochastic singularity check with `heteroskedastic_shocks`Johannes PfeiferJohannes Pfeiferhttps://git.dynare.org/Dynare/dynare/-/issues/1858Use MEX to create stacked Jacobian in two-boundaries blocks with block decomp...2022-09-13T15:50:11ZSébastien VillemotUse MEX to create stacked Jacobian in two-boundaries blocks with block decompositionThe `perfect_foresight_problem` MEX was introduced so as to speed-up the construction of the stacked Jacobian for deterministic problems (when there are both leads and lags).
However, when doing block decomposition, there is no equivale...The `perfect_foresight_problem` MEX was introduced so as to speed-up the construction of the stacked Jacobian for deterministic problems (when there are both leads and lags).
However, when doing block decomposition, there is no equivalent MEX for constructing the stacked Jacobian for two-boundaries blocks. This is an obvious opportunity for optimization.
It remains to be seen how much can be factorized with the existing `perfect_foresight_problem` MEX. The bytecode case may also need special treatment.https://git.dynare.org/Dynare/dynare/-/issues/1864SMM: add support for filters like HP-filter.2022-08-23T08:47:32ZJohannes PfeiferSMM: add support for filters like HP-filter.See https://forum.dynare.org/t/smm-dynare-toolbox-with-binomial-draws/20849/3See https://forum.dynare.org/t/smm-dynare-toolbox-with-binomial-draws/20849/3https://git.dynare.org/Dynare/dynare/-/issues/1857Document data-command or replace it2022-08-10T15:09:00ZJohannes PfeiferDocument data-command or replace itCurrently, to get a `dseries`object loaded into estimation, we use
```
ts = dseries('fsdat_simul.m');
data(series=ts, first_obs=1950Q3, last_obs=2000Q3);
```
(see https://git.dynare.org/Dynare/dynare/-/blob/master/tests/dates/fs2000.mod...Currently, to get a `dseries`object loaded into estimation, we use
```
ts = dseries('fsdat_simul.m');
data(series=ts, first_obs=1950Q3, last_obs=2000Q3);
```
(see https://git.dynare.org/Dynare/dynare/-/blob/master/tests/dates/fs2000.mod). But that `data`-command is not documented as it belongs to the new estimation interface (https://git.dynare.org/Dynare/dynare/-/issues/226). The documentation at https://archives.dynare.org/DynareWiki/NewEstimation seems outdated.Stéphane Adjemianstepan@adjemian.euStéphane Adjemianstepan@adjemian.euhttps://git.dynare.org/Dynare/dynare/-/issues/827Feature request: Implement the algorithm of Ajevskis (2014) for perturbation ...2022-06-01T13:24:06ZTom HoldenFeature request: Implement the algorithm of Ajevskis (2014) for perturbation around a deterministic pathViktors Ajevskis has a [great new paper](https://ideas.repec.org/p/ltv/wpaper/201401.html) showing how the Lombardo pruning method may be extended to support perturbation around a deterministic path. This seems like a feature that would ...Viktors Ajevskis has a [great new paper](https://ideas.repec.org/p/ltv/wpaper/201401.html) showing how the Lombardo pruning method may be extended to support perturbation around a deterministic path. This seems like a feature that would be a huge benefit to virtually all Dynare users, since it makes it possible to e.g.:
- Solve non-stationary DSGE models, such as those featuring structural change.
- Evaluate the welfare consequences of a permanent change in policy, without sacrificing accuracy along the transition path.
- Obtain increased accuracy for large impulse response exercises.
- Unify the stochastic and non-stochastic simulation engines in Dynare.
It would be great if this could be added to the bottom of your very long to do list!
https://ideas.repec.org/p/ltv/wpaper/201401.htmlhttps://git.dynare.org/Dynare/dynare/-/issues/1532Factorize IRF code into function generate_irfs(M_,options_,oo_)2022-04-21T19:45:02ZJohannes PfeiferFactorize IRF code into function generate_irfs(M_,options_,oo_)Take the fragmented codes from `stoch_simul` and `PosteriorIRFcore1` and put them into one function that is used in those other commands, but can also be called as a standalone. Related to #1531.Take the fragmented codes from `stoch_simul` and `PosteriorIRFcore1` and put them into one function that is used in those other commands, but can also be called as a standalone. Related to #1531.Johannes PfeiferJohannes Pfeifer