Small Semi-Structural Model Error

This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location where you will have to reset your password.
Forum rules
This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location (https://forum.dynare.org) where you will have to reset your password.

Small Semi-Structural Model Error

Postby knightfar » Sun Feb 14, 2016 4:30 pm

Dear all,

I am trying to replicate the impulse response in the paper called “Roles of Exchange Rate in Monetary Policy under Inflation Targeting: A Case Study for Thailand” for a month, and I cannot get dynare to run it right without error. I even met with the author of the paper personally and ask for her advice, but the paper was too old that she cannot remember how it was codded. The last attempt got me pass the steady state calculation. Then I got the error as follow:

Error using print_info (line 45)
Blanchard Kahn conditions are not satisfied: indeterminacy;

Error in stoch_simul (line 98)
print_info(info, options_.noprint, options_);

Error in TEST_M (line 411)
info = stoch_simul(var_list_);

Error in dynare (line 180)
evalin('base',fname) ;

I did look through the forums and found that I can use predetermined_variables. However, my model contains the variables that look back as far as 4 periods, so I do not know how to incorporate this function in my code. (my understanding is it is for t-1 only).

Furthermore, I would like to ask about how to force the variable to take a value of steady state throughout the simulation. As it is shown in the paper where the impulse response is comparing between the cases that exchange rate is exogenized and endogenized.

To conclude. I have two questions.
1. How to fix my code for 4 periods backward looking variable.
2. How can I exogenized the variable to compare impulse response of two cases.

Note: My model is a small semi-structural model, which tailored by the author and here is the link to the paper for the reference (https://www.bot.or.th/Thai/MonetaryPoli ... awadee.pdf)
I am specifically trying to replicate the exercises in section 4. Evidence on the Roles of Exchange Rate: a Small Model Approach

TEST_M.mod
My code
(1.78 KiB) Downloaded 54 times
knightfar
 
Posts: 5
Joined: Sat Feb 13, 2016 1:06 pm

Re: Small Semi-Structural Model Error

Postby jpfeifer » Sat Feb 20, 2016 9:05 am

The way you entered the timing seems correct. What seems incorrect are your model equations. As the model is linearized, all steady state values should be 0. However, when you put
Code: Select all
resid;

before steady and delete the initval block (so that all initial values are 0), there are several equations with residuals that are not 0. How did you come up with
Code: Select all
z_z = 370.31;

for example?
------------
Johannes Pfeifer
University of Cologne
https://sites.google.com/site/pfeiferecon/
jpfeifer
 
Posts: 6940
Joined: Sun Feb 21, 2010 4:02 pm
Location: Cologne, Germany

Re: Small Semi-Structural Model Error

Postby knightfar » Mon Feb 22, 2016 9:05 am

Dear Assistant Professor Johannes Pfeifer,

Since I was trying to replicate the model from the mentioned paper, the values of the parameters are taken directly from the paper. However, there are some constant in the equation that are not mentioned in the paper, so I calculate that from the formula given, namely natural rate of real interest rate, exchange rate, and inflation.

For example, z_z is calculate from the average of the HP filtered of the value 100 x ln(fx x CPIf/ CPI) where fx is foreign exchange rate, CPIf is the US CPI, and CPI is Thailand CPI.

I was worried that my coding will not work, so I tried using the value as given in the paper where it is available. Since you confirm that my timing seems correct. I will try to re-calibrate every parameter from my own data.

Is it possible for me to calibrate these natural rats as if it is one of the parameter? I would like to keep the model simple, so it will be better if these values are constant.

Thank you very much for you suggestion. I am looking forward to your next guidance.
knightfar
 
Posts: 5
Joined: Sat Feb 13, 2016 1:06 pm

Re: Small Semi-Structural Model Error

Postby jpfeifer » Fri Feb 26, 2016 9:59 am

Usually, these constants are just normalized to 1 so that their log is 0 and they drop out. This makes the model purely linear.
------------
Johannes Pfeifer
University of Cologne
https://sites.google.com/site/pfeiferecon/
jpfeifer
 
Posts: 6940
Joined: Sun Feb 21, 2010 4:02 pm
Location: Cologne, Germany


Return to Dynare help

Who is online

Users browsing this forum: Google [Bot] and 15 guests