dynare issueshttps://git.dynare.org/Dynare/dynare/-/issues2019-06-19T15:38:06Zhttps://git.dynare.org/Dynare/dynare/-/issues/688add option to suppress all reporting stdout output2019-06-19T15:38:06ZHoutan Bastaniadd option to suppress all reporting stdout outputi.e., suppress:
Adding Page X
Writing Page X
Compiler Output
Where the file is located
i.e., suppress:
Adding Page X
Writing Page X
Compiler Output
Where the file is located
4.5Houtan BastaniHoutan Bastanihttps://git.dynare.org/Dynare/dynare/-/issues/687update manual for common latex syntax in reports2019-06-19T15:38:06ZHoutan Bastaniupdate manual for common latex syntax in reportse.g. people may want to use a '%' sign in a graph title. Note the fix for this. Also for '\'
e.g. people may want to use a '%' sign in a graph title. Note the fix for this. Also for '\'
4.5Houtan BastaniHoutan Bastanihttps://git.dynare.org/Dynare/dynare/-/issues/686addition bug in dseries2019-06-19T15:38:06ZHoutan Bastaniaddition bug in dseries```
>> a=dseries(ones(3,1))
>> 100-a
```
yields -99 as opposed to 99.
```
>> a=dseries(ones(3,1))
>> 100-a
```
yields -99 as opposed to 99.
4.5Stéphane Adjemianstepan@adjemian.euStéphane Adjemianstepan@adjemian.euhttps://git.dynare.org/Dynare/dynare/-/issues/684Add test and documentation for LMMCP solver2019-06-19T15:38:06ZSébastien VillemotAdd test and documentation for LMMCP solver4.5MichelJuillardMichelJuillardhttps://git.dynare.org/Dynare/dynare/-/issues/680Clarify license of LMMCP2019-06-19T15:38:08ZSébastien VillemotClarify license of LMMCPThe license of `matlab/lmmcp/lmmcp.m` and `matlab/lmmcp/catstruct.m` is unclear.
Once clarified, it should be documented in `license.txt`.
The license of `matlab/lmmcp/lmmcp.m` and `matlab/lmmcp/catstruct.m` is unclear.
Once clarified, it should be documented in `license.txt`.
4.5MichelJuillardMichelJuillardhttps://git.dynare.org/Dynare/dynare/-/issues/679Fix various bugs related to detrending and prefiltering2019-06-19T15:38:06ZJohannes PfeiferFix various bugs related to detrending and prefiltering- `dyn_forecast` adds unlogged steady state if `loglinear` is used
- `dynare_estimation_init` sets the `noconstant` based on the unlogged steady state if `loglinear` is used
- when trends are specified as a function of deep parameters, t...- `dyn_forecast` adds unlogged steady state if `loglinear` is used
- `dynare_estimation_init` sets the `noconstant` based on the unlogged steady state if `loglinear` is used
- when trends are specified as a function of deep parameters, the values are not correctly updated during estimation due to using the base-workspace parameter values and not the updated local ones
- when using trends with the `prefilter` option, the mean shift due to the trend is not accounted for
- when using `first_obs>1`, the higher trend starting point is not taken into account (leads also to problems in recursive forecasting)
4.5Johannes PfeiferJohannes Pfeiferhttps://git.dynare.org/Dynare/dynare/-/issues/678Use of the derivative of an external function directly in the model crashes t...2019-06-19T15:38:08ZJohannes PfeiferUse of the derivative of an external function directly in the model crashes the preprocessorSee email to @sebastien-villemot on June 9th, 2014
See email to @sebastien-villemot on June 9th, 2014
4.5Sébastien VillemotSébastien Villemothttps://git.dynare.org/Dynare/dynare/-/issues/677Deal with treatment of unit roots in identification2019-06-19T15:38:08ZJohannes PfeiferDeal with treatment of unit roots in identification```
var y delta_y x z;
varexo eps_x eps_z;
parameters rho sigma_z sigma_x;
// set parameter values
sigma_z=0.001;
sigma_x=0.01;
rho=0.9;
model;
z=rho*z(-1)+sigma_z*eps_z;
x=x(-1)+sigma_x*eps_x;
y=x+z;
delta_y=y-y(-1);
end;
steady_st...```
var y delta_y x z;
varexo eps_x eps_z;
parameters rho sigma_z sigma_x;
// set parameter values
sigma_z=0.001;
sigma_x=0.01;
rho=0.9;
model;
z=rho*z(-1)+sigma_z*eps_z;
x=x(-1)+sigma_x*eps_x;
y=x+z;
delta_y=y-y(-1);
end;
steady_state_model;
x=0;
z=0;
y=0;
delta_y=0;
end;
//set shock variances
shocks;
var eps_z=1;
var eps_x=1;
end;
steady;
check;
varobs y delta_y;
stoch_simul(order=1,irf=0);
estimated_params;
rho, 0.9;
sigma_z, 0.01;
sigma_x, 0.01;
end;
options_.diffuse_filter=1;
identification(lik_init=3,advanced=1);
```
The treatment of unit roots seems unsatisfactory.
First, one needs to specify
`options_.diffuse_filter=1;`
because `options_` used in `dynare_estimation_init` does not inherit the `lik_init` from the `identification` command (used only in `options_ident`) and also does not accept `diffuse_filter`.
Second, some graphs are empty. My guess is because some unconditional moments are infinite.
4.5Marco RattoMarco Rattohttps://git.dynare.org/Dynare/dynare/-/issues/676Fix compatibility of sensitivity and ML estimation2019-06-19T15:38:08ZJohannes PfeiferFix compatibility of sensitivity and ML estimationSee http://www.dynare.org/phpBB3/viewtopic.php?f=1&t=5681
Email to Marco:
```
There is an obvious bug in set_shocks_param.m. Sigma_e_ should be just Sigma_e. But there seems to be more. In stab_map_.m in
if pprior,
for j=1:...See http://www.dynare.org/phpBB3/viewtopic.php?f=1&t=5681
Email to Marco:
```
There is an obvious bug in set_shocks_param.m. Sigma_e_ should be just Sigma_e. But there seems to be more. In stab_map_.m in
if pprior,
for j=1:nshock,
if opt_gsa.morris~=1,
lpmat0(:,j) = randperm(Nsam)'./(Nsam+1); %latin hypercube
end
if opt_gsa.prior_range
lpmat0(:,j)=lpmat0(:,j).*(bayestopt_.ub(j)-bayestopt_.lb(j))+bayestopt_.lb(j);
end
end
bayestopt_.ub and lb are accessed and they are Inf. lpmat0 then has a bunch of NaNs that should not be there. This seems to be due to ML estimation and should probably be filtered out.
```
4.5Marco RattoMarco Rattohttps://git.dynare.org/Dynare/dynare/-/issues/675Fix bug in dsge_likelihood related to analytic_derivation2019-06-19T15:38:08ZJohannes PfeiferFix bug in dsge_likelihood related to analytic_derivationSee http://www.dynare.org/pipermail/dev/2014-May/003793.html
See http://www.dynare.org/pipermail/dev/2014-May/003793.html
4.5Marco RattoMarco Rattohttps://git.dynare.org/Dynare/dynare/-/issues/673when creating a report with only one table, tmpRepDir is not created and it c...2019-06-19T15:38:08ZHoutan Bastaniwhen creating a report with only one table, tmpRepDir is not created and it crashesSee Eleonora's email from 18h30 27/6/2014
See Eleonora's email from 18h30 27/6/2014
4.5Houtan BastaniHoutan Bastanihttps://git.dynare.org/Dynare/dynare/-/issues/672Use pgfplotstable for report tables instead of latex tables2019-06-19T15:38:08ZHoutan BastaniUse pgfplotstable for report tables instead of latex tablesBefore making the change, ensure it's distributed in MikTex
http://pgfplots.sourceforge.net/pgfplotstable.pdf
Before making the change, ensure it's distributed in MikTex
http://pgfplots.sourceforge.net/pgfplotstable.pdf
4.5Houtan BastaniHoutan Bastanihttps://git.dynare.org/Dynare/dynare/-/issues/671misc changes to dates/dseries2019-06-19T15:38:08ZHoutan Bastanimisc changes to dates/dseries- dates: rename `time` field to something more descriptive. Perhaps `data`
- dates: remove `ndat` field. Should have method that provides this information instead
- dseries: remove `nobs` field. Should have method that provides this info...- dates: rename `time` field to something more descriptive. Perhaps `data`
- dates: remove `ndat` field. Should have method that provides this information instead
- dseries: remove `nobs` field. Should have method that provides this information instead
- dseries: remove `vobs` field. Should have method that provides this information instead
4.5Stéphane Adjemianstepan@adjemian.euStéphane Adjemianstepan@adjemian.euhttps://git.dynare.org/Dynare/dynare/-/issues/670Fix handling of prefiltering and trends in non_linear_dsge_likelihood2019-06-19T15:38:08ZJohannes PfeiferFix handling of prefiltering and trends in non_linear_dsge_likelihood`non_linear_dsge_likelihood` uses
`Y = transpose(DynareDataset.rawdata);`
By accessing `rawdata` instead of data, prefiltering is ignored. Moreover, deterministic trends are not subtracted. I am not sure this is on purpose.
`non_linear_dsge_likelihood` uses
`Y = transpose(DynareDataset.rawdata);`
By accessing `rawdata` instead of data, prefiltering is ignored. Moreover, deterministic trends are not subtracted. I am not sure this is on purpose.
4.5https://git.dynare.org/Dynare/dynare/-/issues/669fullpage LaTeX package causes compilation to break on Windows (is output by w...2019-06-19T15:38:08ZHoutan Bastanifullpage LaTeX package causes compilation to break on Windows (is output by write_latex_dynamic_model)Try to repeat error and find a work around if indeed it is not distributed with MikTex
Try to repeat error and find a work around if indeed it is not distributed with MikTex
4.5Houtan BastaniHoutan Bastanihttps://git.dynare.org/Dynare/dynare/-/issues/667rename hessian.m in dyn_hessian.m2019-06-19T15:38:08ZMichelJuillardrename hessian.m in dyn_hessian.mIn order to avoid name collision with other Matlab program/toolboxe
In order to avoid name collision with other Matlab program/toolboxe
4.5https://git.dynare.org/Dynare/dynare/-/issues/666Fix trust-region termination criterion2019-02-08T08:30:47ZJohannes PfeiferFix trust-region termination criterionThe following mod-file says a steady state has been computed, but the residuals show that is not the case. I have no clue why.
```
//-------------------------//
// 1. Endogenous Variables //
//-------------------------//
var
Y,YFstar,
P...The following mod-file says a steady state has been computed, but the residuals show that is not the case. I have no clue why.
```
//-------------------------//
// 1. Endogenous Variables //
//-------------------------//
var
Y,YFstar,
PH,P,PHstar,Pstar,PF,PFstar,
Pi,Pistar,PiH,PiF,PiHstar,PiFstar,
C,Cstar,
i,istar,
DF,DFstar,
S,Q,
W,N,Wstar,Nstar,
CC,
F, K, Fstar, Kstar, PD,PDstar,
A, Astar,RP,U;
//---------------------//
// 2. Exogenous shocks //
//---------------------//
varexo
e, // [E.1] Home Productivity Shock
estar, // [E.2] Foreign Productivity Shock
erp; // [E.3] Risk Premium Shock
//--------------------//
// 3. Parameter names //
//--------------------//
parameters
BETA,SIGMA,PHI,ETA,THETA,EPSILON,CHI,ALPHA,ALPHAstar,TAUL,KAPPA,PHIPIH,PHIY,DBar;
//---------------------//
// 4. Parameter values //
//---------------------//
BETA = .99; // [P.1] Intertemporal Discount Factor
SIGMA = 1; // [P.2] Coefficient of Risk Aversion
PHI = 3; // [P.3] Inverse of Labor Supply elasticity
ETA = 3; // [P.4] Elasticity of Substitution btw Home and Foreign Goods For Gali and Monacelli it is 1 and foreign economy does not effect
THETA = 1-(0.75^4); // [P.5] Price stickiness parameter this value implies average period of one year btw price adjustments
EPSILON = 6; // [P.6] Elasticity of substitution among goods
CHI = 0.000742; // [P.7] Following Justiano and Preston (2010)
ALPHA = 0.4; // [P.8] Degree of Openness(Following Gali and Monacelli (2005))
ALPHAstar = 0.000001; // [P.9] Degree of Openness for Foreign Economy I assume it is a closed economy
TAUL = -1/EPSILON; //[P.10] Steady State Labor Tax Gali and Monacelli (2005)
PHIPIH = 4; // [P.11] Weight of Domestic Inflation in Policy Rule
PHIY = 0.2; // [P.12] Weight of Output in Policy Rule
KAPPA = 0.66; //Autoregressive Coefficient CHECK!!!
DBar = 1.0105;
//---------------------//
// 5A. Model Equations //
//---------------------//
model;
//---------DEMAND BLOCK-----//
Y=(1-ALPHA)*(PH/P)*C+ALPHAstar*(PHstar/Pstar)*Cstar;
//Y = (1-ALPHA)*((S*Pstar*PH)/(P*PF))^(-ETA)*C+ALPHA*(PF/PH)*Cstar; // [1] Home demand equation // [2] Demand for home goods by home consumers
DF=-DFstar;//YFstar=Cstar; // [4] Demand for foreign goods by foreign consumers
YFstar=Cstar;
//C=BTHETA*Cstar*Q^(1/SIGMA);
//(BTHETA(+1)/BTHETA)^SIGMA=((1+i)*S)/((1+istar+((CHI*(exp(DF-DBar)-1)+RP)))*S(+1)*(1+CC));
//NFA=-(Cstar^SIGMA)*((PH*Y/PF)-C/Q)+BETA*NFA(+1);
//---------Price Indexes-----//
P^(1-ETA)=((1-ALPHA)*(PH^(1-ETA))+ALPHA*(PF^(1-ETA))); //[5] Home Price Index
Pstar^(1-ETA)=((ALPHAstar)*(PHstar^(1-ETA))+(1-ALPHAstar)*(PFstar^(1-ETA))); //[6] Foreign Price Index
//---------Euler Equations-----//
(BETA)*(1+i)=((C(+1)/C)^(SIGMA))*(P(+1)/P); //[7] Home Euler Equation (Domestic Bonds)
(BETA)*((1+istar)*((CHI*(exp(DF-DBar)-1)+RP)))*(1+CC)=((C(+1)/C)^(SIGMA))*(P(+1)*S/(P*S(+1))); //[8] Home Euler Equation (Foreign Bonds)
(BETA)*(1+istar)=((Cstar(+1)/Cstar)^(SIGMA))*Pistar; //[9] Foreign Euler Equation
//---------Budget Constraints-----//
P*C+((S*DF)/((1+istar)*(CHI*(exp(DF-DBar)-1)+RP)))=W*N+(1+CC(-1))*S*DF(-1); //[10] Home Budget Constraint
Pstar*Cstar+(DFstar/(1+istar))=Wstar*Nstar+DFstar(-1); //[11] Foreign Budget Constraint
//---------Labor Market Conditions-----//
W/P=(C^(SIGMA))*(N^(PHI)); //[12] Home Market Condition
Wstar/Pstar=(Cstar^(SIGMA))*(Nstar^(PHI)); //[13] Foreign Market Condition
//---------Some Identities, Terms of Trade-----//
Pi=P(+1)/P; //[14] Home inflation Index
Pistar=Pstar(+1)/Pstar; //[15] Foreign inflation Index
Q=S*Pstar/P; //[16] Real Exchange Rate
PiH=PH(+1)/PH; //[17] Domestic Good Price Inflation
PH=S*PHstar; //[18] Law of One Price
PiHstar=PHstar(+1)/PHstar; //[19] Domestic Goods Inflation in Foreign Country
PiF=PF(+1)/PF; // [20] Foreign Good Price Inflation
PF=S*PFstar; //[21] Law of One Price
PiFstar=PFstar(+1)/PFstar; //[22] Foreign Good Inflation in Foreign Country
//Pi=PiH*((PF*Q(-1)*PH(-1))/PH*Q*PF(-1));
//-------------------Price Setting-----------------//
(1-(THETA*(PiH(-1)^(EPSILON-1))))/((1-THETA)*(PH^(EPSILON-1)))= (F/K)^(EPSILON-1); //[23] FOC for Home Country optimal price setting
(1-(THETA*(PiFstar(-1)^(EPSILON-1))))/((1-THETA)*(PF^(EPSILON-1)))= (Fstar/Kstar)^(EPSILON-1); //[24] FOC for Foreign Country optimal price setting
K=(EPSILON/(EPSILON-1))*((1+TAUL)/A)*(W/P)+THETA*BETA*K(+1); //[25] Farhi pg.14
F=Y*(C^-SIGMA)/P+THETA*BETA*F(+1); //[26] Farhi pg.14
Kstar=(EPSILON/(EPSILON-1))*((1+TAUL)/Astar)*(Wstar/Pstar)+THETA*BETA*Kstar(+1); //[27] Farhi pg.14
Fstar=YFstar*(Cstar^-SIGMA)/Pstar+THETA*BETA*Fstar(+1); //[28] Farhi pg.14
PD=THETA*PD(-1)*(Pi^EPSILON)+(1-THETA)*((1-THETA*(Pi^(EPSILON-1)))/(1-THETA))^(EPSILON/EPSILON-1); //[29] Home Price Dispersion
PDstar= THETA*PDstar(-1)*(Pistar^EPSILON)+(1-THETA)*((1-THETA*(Pistar^(EPSILON-1)))/(1-THETA))^(EPSILON/EPSILON-1); //[30] Foreign Price Dispersion
//-------------------Policy Rules-----------//
(1+i)=(Pi^PHIPIH)*(Y^PHIY); //[31] Domestic Policy Rule
(1+istar)=(Pistar^PHIPIH)*(YFstar^PHIY); //[32] Foreign Policy Rule
//-------------------Aggregate Constaints---------//
N=Y*PD/A; //[33] Home Aggregate Constraint
Nstar=YFstar*PDstar/Astar; //[34] Foreign Aggregate Constraint
//-------------------Market Clearing Conditions---------//
//Q=((1-ALPHA)*((S*PFstar/PH)^(ETA-1))+ALPHA)^(1/ETA-1); //[35] Home
//[36] Foreign
//-------------------Exogenous Shocks---------//
log(A) = KAPPA*log(A(-1)) + e;
log(Astar) = KAPPA*log(Astar(-1)) + estar;
log(RP)=KAPPA*log(RP(-1))+erp;
U= (log(C))-((N^(1-PHI))/(1-PHI))+BETA*U(+1);
end;
initval;
Y= 1.05086;
YFstar= 1.04467;
PH= 1.1761;
P= 0.785854;
PHstar= 1.0605;
Pstar = 0.526893;
PF = 0.580829;
PFstar = 0.526852;
Pi = 0.999844;
Pistar = 1.00096;
PiH = 1.00008;
PiF = 1;
PiHstar = 1;
PiFstar = 1.00021;
C = 1.17079;
Cstar = 1.04738;
i = 0.00980802;
istar = 0.0127093;
DF = 5.11019;
DFstar = -5.10995;
S = 1.10883;
Q = 0.743614;
W = 1.05344;
N = 1.04634;
Wstar = 0.597805;
Nstar = 1.02732;
CC = -0.0839033;
F = 3.53735;
K = 4.16102;
Fstar = 5.84907;
Kstar = 3.39894;
PD = 0.995089;
PDstar = 1.01231;
A = 0.998126;
Astar = 1.02965;
RP = 0.998604;
U = 61.3578;
end;
resid(1);
steady(solve_algo=4,maxit=10000);
resid(1);
```
4.5Sébastien VillemotSébastien Villemothttps://git.dynare.org/Dynare/dynare/-/issues/665support looser syntax for creating dates2019-06-19T15:38:08ZHoutan Bastanisupport looser syntax for creating datesRight now, the following syntax works:
`dates(4, [1990; 1991], [1; 2]);`
but
`dates(4, [1990 1991], [1 2]);`
doesn't. What is important is that the arrays passed be vectors, not that they be column vectors or row vectors. We should ease ...Right now, the following syntax works:
`dates(4, [1990; 1991], [1; 2]);`
but
`dates(4, [1990 1991], [1 2]);`
doesn't. What is important is that the arrays passed be vectors, not that they be column vectors or row vectors. We should ease the syntax to accept both, just checking that they are indeed vectors.
4.5Stéphane Adjemianstepan@adjemian.euStéphane Adjemianstepan@adjemian.euhttps://git.dynare.org/Dynare/dynare/-/issues/664Identification and var_exo_det2019-06-19T15:38:08ZJohannes PfeiferIdentification and var_exo_detBoth are not compatible because in calls to the dynamic file the components of `oo_.exo_det_steady_state` neglect x.
Either filter out those cases or make them compatible.
Both are not compatible because in calls to the dynamic file the components of `oo_.exo_det_steady_state` neglect x.
Either filter out those cases or make them compatible.
4.5Marco RattoMarco Rattohttps://git.dynare.org/Dynare/dynare/-/issues/662Update and fix gsa/set_shocks_param.m2019-06-19T15:38:08ZJohannes PfeiferUpdate and fix gsa/set_shocks_param.mApart from an obvious typo (`Sigma_e_` instead `Sigma_e`) it seems as if that file is still missing the update to reflect calibrated covariances (#511).
Apart from an obvious typo (`Sigma_e_` instead `Sigma_e`) it seems as if that file is still missing the update to reflect calibrated covariances (#511).
4.5Marco RattoMarco Ratto