Taylor(1979) Optimal Control
Posted: Wed Jan 20, 2010 11:30 am
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.
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 beta0
dec real gamma1 gamma0
dec real theta1 theta2
*
* Taylor's estimates
*
compute beta1=1.167
compute beta2=-.324
compute beta3=.578
compute beta4=-.484
compute beta5=-.447
compute beta6=.0000843
compute beta0=.0720
compute gamma1=.0180
compute gamma0=.000515
compute theta1=-.38
compute 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*t
dec 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 i
scatter(footer="Figure 1. Output-inflation variance tradeoff",style=line)
# inflsd outputsd 1 99