Taylor(1979) Optimal Control

Discussion of State Space and Dynamic Stochastic General Equilibrium Models

Taylor(1979) Optimal Control

This does the calculation of the steady-state optimal control law, and graphs the variance trade-off between output and inflation from
from Taylor (1979), "Estimation and Control of a Macroeconomic Model with Rational Expectations," Econometrica, vol. 47(5), pages 1267-86.

Code: Select all
`** Replication file for Taylor (1979), "Estimation and Control of a* Macroeconomic Model with Rational Expectations," Econometrica,* vol. 47(5), pages 1267-86.** Calculation of policy rule.*dec real beta1 beta2 beta3 beta4 beta5 beta6 beta0dec real gamma1 gamma0dec real theta1 theta2** Taylor's estimates*compute beta1=1.167compute beta2=-.324compute beta3=.578compute beta4=-.484compute beta5=-.447compute beta6=.0000843compute beta0=.0720compute gamma1=.0180compute gamma0=.000515compute theta1=-.38compute theta2=+.67*compute a=1.0/(1-beta5*gamma1)** Transition matrix* There are sign errors in both elements in the fifth column, and a typo* in the 4,3 element, which should read as below*compute adlm=a*\$||   beta1   ,    beta2   ,    beta4   ,beta5 ,-(beta5*theta2+theta1)|\$     1.0/a   ,      0     ,      0     ,  0   ,    0  |\$       0     ,      0     ,      0     ,  0   ,    0  |\$ gamma1*beta1,gamma1*beta2,gamma1*beta4,  1   ,-(gamma1*theta1+theta2)|\$       0     ,      0     ,      0     ,  0   ,    0  ||** Coefficients on control variable*compute bdlm=a*||beta3|0|1.0/a|gamma1*beta3|0.0||** Loadings from shocks to states*compute fdlm=||\$  1.0,0.0|\$  0.0,0.0|\$  0.0,0.0|\$  0.0,1.0|\$  0.0,1.0||compute swdlm=%diag(||.007916^2,.003661^2||)*set lgrid 1 99 = -10.0+.2*tdec vect g(5)do i=1,99   compute lambda=%logistic(lgrid(i),1.0)   compute qdlm=%diag(||lambda,0.0,0.0,1-lambda,0.0||)   compute g=%zeros(5,1)   *   * Iterate to get steady-state control law   *   compute h=qdlm   do iters=1,100      compute h=qdlm+%mqform(h,adlm+bdlm*tr(g))      compute g=-1.0*inv(%mqform(h,bdlm))*tr(bdlm)*h*adlm   end do iters   compute adp=adlm+bdlm*tr(g)   *   * Compute ergodic covariance matrix   *   compute sx0=%psdinit(adp,fdlm*swdlm*tr(fdlm))   set outputsd i i = 100.0*sqrt(sx0(1,1))   set inflsd   i i = 400.0*sqrt(sx0(4,4))end do iscatter(footer="Figure 1. Output-inflation variance tradeoff",style=line)# inflsd outputsd 1 99`
TomDoan

Posts: 2727
Joined: Wed Nov 01, 2006 5:36 pm