Please help see my code

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.

Please help see my code

Postby undergradEcon » Sun Apr 14, 2013 4:15 am

I am confused why a positive sd. shock on variable "q" gives the impulse response of "q" with an immediately fall instead of immediately rise?
Please suggest me. Thanks in advance.

Code: Select all
var pih x y ynat rnat r s pi p ph e ystar a pistar q ;                               
varexo q_ ;                         
parameters sigma rho tau alpha theta xi beta kappa omega phipi rhoa rhoy lambda gamma delta rhopih;

sigma = 1;
rho  = 0.0101;
tau   = 1;
alphas = 0.4;
theta = 0;
beta  = 0.99;
kappa = 0.3433;
omega = -0.1277;
xi    = 0;
phipi = 1.5;
rhoa = 0.66;                                                                 
rhoy = 0.86;                                                                 
gamma = 2.4 ;
delta = 1.6 ;
rhopih = 0.8;

                                                                 
model(linear);
x    = x(+1) - ( r - pih(+1) - rnat) ;                             
rnat = -sigma*tau*(1-rhoa)*a + alpha*sigma*(theta+xi)*(rhoy-1)*ystar;         
pih  = beta * pih(+1)+ kappa*x;                                               
ynat = tau*a + alpha*xi*ystar;                                                 
x    = y - ynat ;                                                             
q    = (1-alpha)*s;
q =  gamma*( pih ) + delta*x + q_;                                       
y    = ystar +(sigma)^(-1)*s;                                                             
pi   = pih + alpha*(s-s(-1));                                                 
pi   = p - p(-1);                                                             
pih  = ph - ph(-1);                                                           
s    = s(-1) + e - e(-1) + pistar - pih;                                     
pistar = 0;                                                                   
a    = rhoa*a(-1) ;                                                             
ystar= rhoy*ystar(-1) ;                                                         
end;

shocks;                                             
var q_ =0.52^2;
end;

stoch_simul(order=1, irf=20, noprint ) pih pi x r s e q;
undergradEcon
 
Posts: 4
Joined: Thu Mar 07, 2013 11:32 am

Re: Please help see my code

Postby jpfeifer » Sun Apr 14, 2013 7:31 am

Either you have a mistake or you the endogenous variables in your model respond in a way to counteract the initial shock. For example, in the standard New Keynesian model the nominal interest rate can move in either direction after a contractionary monetary policy shock. The only thing that is guaranteed is that the real interest rate increases.
------------
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: Please help see my code

Postby undergradEcon » Sun Apr 14, 2013 9:33 am

Million of Thanks Jpfeifer!!
Actually in my model, 'q ' is the real exchange rate I add as a monetary policy rule. The initial model employ 'r' interest rate instead of q in the monetary policy rule.
I am really worry whether it will work to add 'q' in this ad-hoc fashion. And now the interpretation is weird that the depreciation shock(positive shock) lower the interest rate.
All suggestions are welcomed.
Again thank you very much!!
undergradEcon
 
Posts: 4
Joined: Thu Mar 07, 2013 11:32 am


Return to Dynare help

Who is online

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