Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- close all
- % [1] Declare variables and parameters
- var m v u theta J W U f q w n y z;
- varexo ez;
- parameters beta chi alpha c s phi b rhoz sigmaz mss vss
- uss thetass Jss Wss Uss fss qss wss nss yss zss;
- % [2] Declare variables and parameters
- beta=0.99; % quarterly rate to get a 4% annual real interest rate
- alpha=0.5; % Hosios condition
- phi=0.5; % Hosios condition
- uss=0.08; % Target unemployment rate of 8% on average from data
- s=0.04; % Target observed separation rate from data
- sigmaz=0.007; % standard values for AR(1) process in the RBC litterature
- rhoz=0.9; % standard values for AR(1) process in the RBC litterature
- nss=1-uss; % by definition from equation 11
- fss=nss*s/uss; %job finding rate obtain from steady state equation 10
- qss=0.9; % fixed from Andolfatto paper (1996);
- thetass=fss/qss; % tightness obtained from f/q
- vss=thetass*uss; % vacancies obtained theta=v/u
- zss=0;
- yss=1;
- b=0.5; % b fixé
- c=beta*(yss-(1-phi)*yss-phi*b)/(1/qss+beta*(1-phi)*thetass-beta*(1-s)*1/qss);
- wss=(1-phi)*(yss+c*thetass)+phi*b; % Equation 9;
- mss=fss*uss;
- chi=mss/(uss^alpha*vss^(1-alpha));
- Jss=(yss-wss)/(1-beta*(1-s));
- % [3] Declare model’s equations
- model;
- m=chi*u^alpha*v^(1-alpha); % 1
- f=m/u; % 2
- q=m/v;% 3
- theta=v/u;% 4
- U=b+beta*(f*W(+1)+(1-f)*U(+1)); % 5
- W=w+beta*(s*U(+1)+(1-s)*W(+1));% 6
- J=y-w+beta*(1-s)*J(+1);% 7
- c/q=beta*J(+1);% 8
- w=(1-phi)*(y+c*theta)+phi*b;% 9
- u=u(-1)+n(-1)*s-f(-1)*u(-1);% 10
- n=1-u; % 11
- y=exp(z);% 12
- z=rhoz*z(-1)+ez;% 13
- end;
- % [4] Set initial value for steady state
- initval;
- m=mss;
- v=vss;
- u=uss;
- theta=thetass;
- J=Jss;
- W=1;
- U=1;
- f=fss;
- q=qss;
- w=wss;
- n=nss;
- y=yss;
- z=zss;
- end;
- % CHECK for residual
- resid(1);
- % ASK dynare to calculate the steady state
- steady;
- resid(1);
- pause
- % [6] Declare shock variance
- shocks;
- var ez; stderr sigmaz;
- % var ex; stderr 0.04;
- end;
- % [7] Simulation command
- stoch_simul(irf=30, periods=2000) u;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement