File:Godley-lavoie-chapter-3-sfc-model-plot.svg

Page contents not supported in other languages.
This is a file from the Wikimedia Commons
From Wikipedia, the free encyclopedia

Original file(SVG file, nominally 619 × 499 pixels, file size: 78 KB)

Summary

Description
English: Plot of model SIM from textbook Monetary Economics by Wynne Godley and Marc Lavoie, 2007. Initial and parameter values, see source code in python below.
Deutsch: Plot des Modells SIM aus dem Textbuch Monetary Economics von Wynne Godley und Marc Lavoie, 2007. Für Parameter und Anfangsbedingungen, siehe Quellcode in python unten.
Date
Source Own work
Author Sfcler
SVG development
InfoField
W3C grn 
The SVG code is valid.
Created with Matplotlib-logo 
This plot was created with Matplotlib.
Source code
InfoField

Python code

#!/usr/bin/env python

from pylab import array, plot, zeros, ones, arange, figure, NaN

tmax=50

alpha1=0.6; alpha2=0.25 # consumption parameters
theta =0.2 # tax rate

# define model SIM

H_time = zeros(tmax); H_time[0]=25
C_time = zeros(tmax); C_time[0]=NaN
G_time = ones(tmax) * 20
T_time = zeros(tmax); T_time[0]=NaN
Y_time = zeros(tmax); Y_time[0]=NaN
Yd_time = zeros(tmax); Yd_time[0]=NaN

for tstep in range(1,tmax):
    C_time[tstep] = (alpha2*H_time[tstep-1]+alpha1*G_time[tstep]*(1-theta))/(1.-alpha1*(1-theta))
    H_time[tstep] = H_time[tstep-1]+(1-theta)*G_time[tstep]-theta*C_time[tstep]
    Y_time[tstep] = C_time[tstep] + G_time[tstep]
    T_time[tstep] = theta * Y_time[tstep]
    Yd_time[tstep] = Y_time[tstep]-T_time[tstep]

# plot time evolution of stocks
fig1 = figure()
ax1 = fig1.add_subplot(111)
ax1.set_xlabel(r"$t$",fontsize=14)

ax1.plot(arange(tmax),H_time,'ok',label=r"$H_h = H_s$")
ax1.plot(arange(tmax),Y_time,'^m',label=r"$Y$")
ax1.plot(arange(tmax),Yd_time,'vw',label=r"$Y_d$")
ax1.plot(arange(tmax),C_time,'sb',label=r"$C$")
ax1.plot(arange(tmax),G_time,'<r',label=r"$G$")
ax1.plot(arange(tmax),T_time,'>y',label=r"$T$")

ax1.legend(loc="upper left", frameon=False).get_frame().set_facecolor('none')

fig1.savefig("godley-lavoie-chapter-3-sfc-model-plot.svg", bbox_inches = 'tight')

Plot generated using python (scipy, numpy, matplotlib). Source code: CC-0.

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
Creative Commons CC-Zero This file is made available under the Creative Commons CC0 1.0 Universal Public Domain Dedication.
The person who associated a work with this deed has dedicated the work to the public domain by waiving all of their rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law. You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission.

Captions

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts

10 January 2019

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current15:48, 12 January 2019Thumbnail for version as of 15:48, 12 January 2019619 × 499 (78 KB)Sfclerplot all variables
23:53, 10 January 2019Thumbnail for version as of 23:53, 10 January 2019619 × 499 (57 KB)SfclerUser created page with UploadWizard
The following pages on the English Wikipedia use this file (pages on other projects are not listed):

Global file usage

The following other wikis use this file:

Metadata