Page 1 of 1

Bayoumi and Eichengreen (1993)

Posted: Mon Apr 02, 2012 5:25 pm
by WALLE
Hello :D

I am trying to replicate the procedure as in Bayoumi and Eichengreen(1993)* to investigate the similarities between demand and supply shocks among countries in the West African Monetary zone (WAMZ) - Nigeria, Ghana, Sierra Leone, Liberia, Gambia and Guinea. These countries intend to form a monetary zone called 'the Eco' by 2015 (on paper i.e :wink: )

Bayoumi and Eichengreen(1993) estimate bi-variate VARs of output growth and inflation across the several countries in the sample using the Blanchard and Quah identification procedure. They then obtain correlations between the supply and demand shocks among all countries, which is where i'm stuck

here's my code for one country:

Code: Select all

***************************************************************************
*LIBERIA
***************************************************************************

OPEN DATA "C:\Users\WALE OKUNRINBOYE\Documents\monetary union\New folder (2)\Liberia.xlsx"
CALENDAR(A) 1960:1
DATA(FORMAT=XLSX,ORG=COLUMNS,LEFT=2) 1960:01 2010:01 LIB_NGDP LIB_RGDP LIB_INF

table

************************************************************************
*PRELIMINARY TRANSFORMATIONS
************************************************************************
*TAKING LOGS
SET L_LIB_RGDP = LOG(LIB_RGDP)
SET L_LIB_NGDP = LOG(LIB_NGDP)
*OUTPUT GROWTH RATES
SET LIB_OUTPUT = L_LIB_RGDP-L_LIB_RGDP{1}

***************************************************************
*SET UP/ESTIMATE VAR SYSTEM
***************************************************************
compute [vect[strings]] shocklabels=||"Supply","Demand"||
compute [vect[strings]] varlabels=||"Output","Inflation"||

compute neqn = 2
compute nlags = 2
compute nsteps = 12
compute ndraws = 10000

system(model=libvar)
variables LIB_OUTPUT LIB_INF 
lags 1 to nlags
det constant
end(system)

estimate(noprint,resids=resids)

**************************************************************************************
* Compute the Blanchard-Quah factorization of the covariance matrix
***************************************************************************************
compute bqfactor=%bqfactor(%sigma,%varlagsums)

@structresids(factor=bqfactor) resids %regstart() %regend() sresids
Then, i replicate the same procedure for the remaining 5 countries.
First Question - So far is my code in order?
Second Question - Are the values stored in 'sresids(i=1,2)' the supply and demand shocks? If yes then these are the values to be used in capturing the correlations between each countries and an 'anchor' country - which in my case would be Nigeria as the biggest economy in the zone.

*Bayoumi, T. and Eichengreen, B. (1993) ‘Shocking Aspects of Monetary European
Monetary Unification’. In Giavazzi, F. and Torres, F. (eds) The Transition to Economic and Monetary Union in Europe (Cambridge: Cambridge University Press).

Many thanks,

Walle

Re: Bayoumi and Eichengreen (1993)

Posted: Tue Apr 03, 2012 9:53 am
by TomDoan
WALLE wrote:Hello :D

I am trying to replicate the procedure as in Bayoumi and Eichengreen(1993)* to investigate the similarities between demand and supply shocks among countries in the West African Monetary zone (WAMZ) - Nigeria, Ghana, Sierra Leone, Liberia, Gambia and Guinea. These countries intend to form a monetary zone called 'the Eco' by 2015 (on paper i.e :wink: )

Bayoumi and Eichengreen(1993) estimate bi-variate VARs of output growth and inflation across the several countries in the sample using the Blanchard and Quah identification procedure. They then obtain correlations between the supply and demand shocks among all countries, which is where i'm stuck

Then, i replicate the same procedure for the remaining 5 countries.
First Question - So far is my code in order?
Looks fine.
WALLE wrote: Second Question - Are the values stored in 'sresids(i=1,2)' the supply and demand shocks? If yes then these are the values to be used in capturing the correlations between each countries and an 'anchor' country - which in my case would be Nigeria as the biggest economy in the zone.
Correct. They are supply and demand in that order.

Probably the quickest way to set up what you need is to do six programs, one for each country. At the end of each, copy the structural residuals to a separate file. (Probably the best way is to use format=free,org=columns). In a separate program, read those back, except this time start with

Code: Select all

dec vect[series] supply(6) demand(6)
open data mynigeriashocks.txt
data(format=free,org=obs) / supply(1) demand(1)
open data myliberiashocks.txt
data(format=free,org=obs) / supply(2) demand(2)
...
Then you can analyze the set of six supply shocks or six demand shocks with VCV to get the pairwise correlations.

Re: Bayoumi and Eichengreen (1993)

Posted: Tue Apr 03, 2012 5:22 pm
by WALLE
Thanks Tom :D

Re: Bayoumi and Eichengreen (1993)

Posted: Thu Jun 21, 2012 3:24 am
by basher
Hello,

I am using RATS' BQ procedure to estimate a SVAR similar to Bayoumi and Eichengreen. In addition to obtaining the structural shocks, I want to calculate the "size" as well as the "persistence" of the demand and supply shocks. In Bayoumi and Eichengreen, the size (or magnitude) is inferred by considering the associated impulse response functions. So, for the supply disturbances, the magnitude is measured as the "long-run output effect", whereas for the demand disturbances, the magnitude is measured as the "sum of the first-year impact on output and prices". As for the speed of adjustment (persistence parameter), is it summarized by the "response after two years as a share of the long-run effects."

I need help on RATS syntax to compute the size and persistence measures. Thank you.

Re: Bayoumi and Eichengreen (1993)

Posted: Thu Jun 21, 2012 7:24 am
by TomDoan
The sum of the first year responses would be done with

SSTATS 1 4 series of responses>>firstyear

The long run response matrix is computed with something like:

compute longrunresp=inv(%varlagsums)*bqfactor

Re: Bayoumi and Eichengreen (1993)

Posted: Fri Jun 22, 2012 12:53 am
by basher
Thank you Tom. I am still facing problems in computing the "size" and "persistence" measures discussed above. So I am providing the BQ-procedure I am using for my empirical analysis:
***********************************************************************************
cal 1970
open data bqcaus.xls
data(format=xls,org=cols) 1970 1989 rgdp_ca inf_ca rgdp_us inf_us

compute nsteps = 10
compute neqn = 2

system(model=bqmodel)
var rgdp_ca inf_ca
lags 1 to 2
det constant
end(system)

estimate(noprint,resids=resids)
compute factor=%bqfactor(%sigma,%varlagsums)
{
if factor(1,2)<0.0
compute factor=factor*%diag(||1.0,-1.0||)
}
@varirf(model=bqmodel,decomp=factor,steps=nsteps,page=byshocks,$
variables=||"Output","Price"||,shocks=||"Supply","Demand"||,accum=||1||)

declare rect[series] impblk(neqn,neqn)
declare vect[series] scaled(neqn)
declare vect[strings] implabel(neqn)

history(model=bqmodel,factor=factor,results=histdecomp)
@StructResids(factor=factor) resids / sresids
report(action=define)
report(atrow=1,atcol=1,align=center) "Year" "Demand(Percent)" "Supply(Percent)"
do time=1970,1989
report(row=new,atcol=1) %datelabel(time) sresids(2)(time) sresids(1)(time)
end do time
report(action=format,picture="*.#")
report(action=show)

impulse(model=bqmodel,result=impblk,print,$
steps=nsteps,cv=%sigma)

***********************************************************************************

I am trying to replicate Bayoumi and Eichengreen (1993) for Canada and the US (so I am also attaching the variables they used, the data are not exactly identical due to revision). It would be very helpful to get further help in computing these measures. Thank you once again.

Re: Bayoumi and Eichengreen (1993)

Posted: Fri Jun 22, 2012 7:20 am
by TomDoan
Could you be much more specific about the calculation that you want. Bayoumi and Eichengreen wrote about ten papers in a short period, and you are talking about a specific calculation in one of them. Most of the papers are just digitized scans so there's no way to do a PDF search to find phrases.

Re: Bayoumi and Eichengreen (1993)

Posted: Fri Jun 22, 2012 7:48 am
by basher
Hello Tom,

I am unable to attach the Bayoumi and Eichengreen (1994) paper, because I have reached the "board attachment quota." Here is the link to their paper:
http://www.princeton.edu/~ies/IES_Studies/S76.pdf

Their SVAR model is shown by equation (5) on page 12. The "size" and "persistence" measures are discussed on page 27 (second paragraph). Basically, I want to replicate their results for Canada and the US as in Tables 5, 6 & 7 using the data supplied above. Thank you so very much.

Re: Bayoumi and Eichengreen (1993)

Posted: Tue Jun 26, 2012 10:50 am
by TomDoan
You need to use the B-Q factor, not a Cholesky factor, to get their measures. The following will compute the supply and demand sizes and the supply speed as they have it defined. (The 1 1 and 1 2 in the SSTATS are for the annual data that you have; with quarterly, they would be 1 4 and 1 8). I have no idea what they are doing for the speed of the demand shock. The long-run response of real GDP to the demand shock is zero by definition. If they mean to use long-run response of nominal GDP as the divisor, that would be the long-run response of prices, which seems like a rather odd way to normalize the speed of reaction of (nominal) GDP.

Code: Select all

impulse(model=bqmodel,result=impblk,print,factor=factor,$
  steps=nsteps)
compute longrunresp=inv(%varlagsums)*factor
compute supplysize=longrunresp(1,1)
*
* Sum over first year responses to demand shocks to get size
*
sstats 1 1 impblk(1,2)(t)+impblk(2,2)(t)>>demandsize
*
* Sum over first two years/long run to get speed
*
sstats 1 2 impblk(1,1)(t)/longrunresp(1,1)>>supplyspeed

Re: Bayoumi and Eichengreen (1993)

Posted: Wed Jun 27, 2012 3:39 am
by basher
Hello Tom, thank you for your generous help. Like the supply speed, the demand speed is also is also summarized by the response after two years as a share of the long-run effect. Since impblk(1,2)(t)/=0 by construction, I guess it makes sense to obtain the persistence of price response to "supply shock" and "demand shock" as follows:

sstats 1 2 impblk(2,1)(t)/longrunresp(1,1)>>speed1
sstats 1 2 impblk(2,2)(t)/longrunresp(1,1)>>speed2

It is not clear which one of the above two speeds is to be interpreted as the speed of demand shock.

Re: Bayoumi and Eichengreen (1993)

Posted: Wed Jun 27, 2012 11:16 am
by TomDoan
That's not how I would have interpreted that, but if it's important to you, you will need to check with the authors to clarify it.