' MODEL LP for Eviews version 5.1 ' from Wynne Godley & Marc Lavoie ' MONETARY ECONOMICS ' Chapter 5 ' This program creates model LP, described in chapter 5, and simulates the model ' to produce results in figures 5.2 - 5.4, discussed in par. 5.7 ' **************************************************************************** ' Copyright (c) 2006 Gennaro Zezza ' Permission is hereby granted, free of charge, to any person obtaining a ' copy of this software and associated documentation files (the "Software"), ' to deal in the Software without restriction, including without limitation ' the rights to use, copy, modify, merge, publish, distribute, sublicense, ' and/or sell copies of the Software, and to permit persons to whom the ' Software is furnished to do so, subject to the following conditions: ' ' The above copyright notice and this permission notice shall be included in ' all copies or substantial portions of the Software. ' ' THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR ' IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, ' FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE ' AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER ' LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING ' FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS ' IN THE SOFTWARE. ' **************************************************************************** ' Create a workfile, naming it LP, to hold annual data from 1945 to 2010 wfcreate(wf=lp, page=annual) a 1945 2010 ' Creates and documents series series b_cb b_cb.displayname Government bills held by Central Bank series b_d b_d.displayname Demand for government bills series b_h b_h.displayname Government bills held by households series b_s b_s.displayname Government bills supplied by government series bl_d bl_d.displayname Demand for government bonds series bl_h bl_h.displayname Government bonds held by households series bl_s bl_s.displayname Supply for government bonds series cg cg.displayname Capital gains on bonds series cg_e cg_e.displayname Expected capital gains on bonds series cons cons.displayname Consumption goods series er_rbl er_rbl.displayname Expected rate of return on bonds series g g.displayname Government goods series h_d h_d.displayname Demand for cash series h_h h_h.displayname Cash money held by households series h_s h_s.displayname Cash money supplied by central bank series p_bl p_bl.displayname Price of bonds series p_bl_e p_bl_e.displayname Expected price of bonds series p_bl_bar p_bl_bar.displayname Exogenously set price of bonds series r_b r_b.displayname Interest rate on government bills series r_bar r_bar.displayname Exogenously set interest rate on government bills series r_bl r_bl.displayname Interest rate on government bonds series t t.displayname Taxes series v v.displayname Households wealth series v_e v_e.displayname Expected households wealth series y y.displayname Income = GDP series yd_r yd_r.displayname Regular disposable income of households series yd_r_e yd_r_e.displayname Expected regular disposable income of households ' Generate parameters series alpha1 alpha1.displayname Propensity to consume out of income series alpha2 alpha2.displayname Propensity to consume out of wealth series chi chi.displayname Weight of conviction in expected bond price series lambda10 lambda10.displayname Parameter in asset demand function series lambda12 lambda12.displayname Parameter in asset demand function series lambda13 lambda13.displayname Parameter in asset demand function series lambda14 lambda14.displayname Parameter in asset demand function series lambda20 lambda20.displayname Parameter in asset demand function series lambda22 lambda22.displayname Parameter in asset demand function series lambda23 lambda23.displayname Parameter in asset demand function series lambda24 lambda24.displayname Parameter in asset demand function series lambda30 lambda30.displayname Parameter in asset demand function series lambda32 lambda32.displayname Parameter in asset demand function series lambda33 lambda33.displayname Parameter in asset demand function series lambda34 lambda34.displayname Parameter in asset demand function series theta theta.displayname Tax rate ' Set sample size to all workfile range smpl @all ' Assign values for ' PARAMETERS alpha1=0.8 alpha2=0.2 chi=0.1 lambda20 = 0.44196 lambda22 = 1.1 lambda23 = 1 lambda24 = 0.03 lambda30 = 0.3997 lambda32 = 1 lambda33 = 1.1 lambda34 = 0.03 theta=0.1938 ' EXOGENOUS g=20 r_bar = 0.03 p_bl_bar = 20 ' Opening values for stocks v = 95.803 b_h = 37.839 b_s = 57.964 b_cb = b_s - b_h bl_h = 1.892 bl_s = bl_h h_s = 20.125 ' Opening values for lagged endogenous yd_r = 95.803 r_b = r_bar p_bl = p_bl_bar ' Shock to interest rates smpl 1960 @last r_bar = 0.04 p_bl_bar = 15 ' Create a model object, and name it lp_mod model lp_mod ' Add equations to model LP ' Determination of output - eq. 5.1 lp_mod.append y = cons + g ' Regular disposable income - eq. 5.2 lp_mod.append yd_r = y - t + r_b(-1)*b_h(-1) + bl_h(-1) ' Tax payments - eq. 5.3 lp_mod.append t = theta*(y + r_b(-1)*b_h(-1) + bl_h(-1)) ' Wealth accumulation - eq. 5.4 lp_mod.append v = v(-1) + (yd_r - cons) + cg ' Capital gains on bonds - eq. 5.5 lp_mod.append cg = (p_bl-p_bl(-1))*bl_h(-1) ' Consumption function - eq. 5.6 lp_mod.append cons = alpha1*yd_r_e + alpha2*v(-1) ' Expected wealth - eq. 5.7 lp_mod.append v_e = v(-1) + (yd_r_e - cons) + cg ' Cash money - eq. 5.8 lp_mod.append h_h = v - b_h - p_bl*bl_h ' Demand for cash - eq. 5.9 lp_mod.append h_d = v_e - b_d - p_bl*bl_d ' Demand for government bills - eq. 5.10 lp_mod.append b_d = v_e*(lambda20 + lambda22*r_b - lambda23*er_rbl - lambda24*(yd_r_e/v_e)) ' Demand for government bonds - eq. 5.11 lp_mod.append bl_d = v_e*(lambda30 - lambda32*r_b + lambda33*er_rbl - lambda34*(yd_r_e/v_e))/p_bl ' Bills held by households - eq. 5.12 lp_mod.append b_h = b_d ' Bonds held by households - eq. 5.13 lp_mod.append bl_h = bl_d ' Supply of government bills - eq. 5.14 lp_mod.append b_s = b_s(-1) + (g + r_b(-1)*b_s(-1) + bl_s(-1)) - (t + r_b(-1)*b_cb(-1)) -p_bl*(bl_s-bl_s(-1)) ' Supply of cash - eq. 5.15 lp_mod.append h_s = h_s(-1) + b_cb - b_cb(-1) ' Government bills held by the central bank - eq. 5.16 lp_mod.append b_cb = b_s - b_h ' Supply of government bonds - eq. 5.17 lp_mod.append bl_s = bl_h ' Expected rate of return on bonds - eq. 5.18 lp_mod.append er_rbl = r_bl+chi*(p_bl_e - p_bl)/p_bl ' Interest rate on bonds - eq. 5.19 lp_mod.append r_bl = 1/p_bl ' Expected price of bonds - eq. 5.20 lp_mod.append p_bl_e = p_bl ' Expected capital gains - eq. 5.21 lp_mod.append cg_e = chi*(p_bl_e - p_bl)*bl_h ' Expected regular disposable income - eq. 5.22 lp_mod.append yd_r_e = yd_r(-1) ' Interest rate on bills - eq. 5.23 lp_mod.append r_b = r_bar ' Price of bonds - eq. 5.24 lp_mod.append p_bl = p_bl_bar ' End of model ' Select the baseline scenario lp_mod.scenario baseline ' Drop first observation to get starting values for solving the model smpl 1946 @last ' Solve the model for the current sample lp_mod.solve ' Creates charts from simulated variables ' Creates the chart in Figure 5.2 smpl 1950 2000 graph fig5_2.line v_0/yd_r_0 fig5_2.setelem(1) lcolor(red) lwidth(2) lpat(1) fig5_2.name(1) Wealth to disposable income ratio fig5_2.addtext(t) Figure 5.2 Evolution of V/Yd following an increase in interest rates fig5_2.scale(left) linear range(0.89, 1.01) show fig5_2 ' Creates the chart in Figure 5.3 smpl 1950 2001 graph fig5_3.line yd_r_0 cons_0 fig5_3.options linepat fig5_3.setelem(1) lcolor(blue) lwidth(2) lpat(1) fig5_3.setelem(2) lcolor(red) lwidth(2) lpat(2) fig5_3.name(1) Disposable income fig5_3.name(2) Consumption fig5_3.addtext(t) Figure 5.3 Evolution of Yd and C following an increase in interest rates show fig5_3 ' Creates the chart in Figure 5.4 smpl 1950 2001 graph fig5_4.line b_h_0/v_0 p_bl_0*bl_h_0/v_0 fig5_4.options linepat fig5_4.setelem(1) lcolor(blue) lwidth(2) lpat(1) fig5_4.setelem(2) lcolor(red) lwidth(2) lpat(2) fig5_4.name(1) Bills to wealth ratio fig5_4.name(2) Bonds to wealth ratio fig5_4.addtext(t) Figure 5.4 Evolution of B/V and BL/V following an increase in interest rates show fig5_4 ' Reset interest rates to starting values smpl @all r_bar = 0.03 p_bl_bar = 20 ' now shock the propensity to consume out of income smpl 1955 @last alpha1=0.7 ' select a new scenario lp_mod.scenario "Scenario 1" ' Drop first observation to get starting values for solving the model smpl 1946 @last ' Solve the model for the current sample lp_mod.solve ' Creates charts from simulated variables ' Creates the chart in Figure 5.10 smpl 1950 2000 graph fig5_10.line y_1 fig5_10.setelem(1) lcolor(red) lwidth(2) lpat(1) fig5_10.name(1) Gross domestic product fig5_10.addtext(t) Figure 5.10 Evolution of GDP following a sharp decrease\rin the propensity to consume out of income show fig5_10