On Wed, 30 Aug 2006, Sven Schreiber wrote:
And how actually does it work now to test the homogeneous
restrictions you mentioned, e.g. via GUI? I wasn't obvious to
me.
Yes, it needs to be documented properly, but here's an example
from Chapter 20 of Hamilton's "Time Series Analysis". The data
file, hamilton.gdt, is supplied with the gretl distribution.
Hamilton's variables are the logs of the US price level, p, the
the US/Lira exchange rate, s, and the Italian price level, pf,
(all monthly, *100, and taken as offsets relative to 1973:01).
He runs a VECM and reports the cointegrating vector, beta, as
(1.00, -0.04, -0.56)'.
Gretl gets:
p(-1) 1.0000
(0.0000)
s(-1) -0.036957
(0.028013)
pf(-1) -0.55680
(0.014770)
OK so far. He then goes on to talk about LR tests regarding the
cointegrating vector.
Test 1: Is the middle coefficient zero? (That is, the
cointegration involves only the two price levels.)
Hamilton works this through to an LR Chi-square(1) of
0.97. I think this is a little approximate. With
gretl we do
restrict
b2 = 0
end restrict
and get
2 * (lu - lr) = 0.97682
P(Chi-Square(1) > 0.97682 = 0.322985
I think this is right.
Test 2: The real exchange rate is stationary, or beta is
proportional to (1, -1, -1)'. In gretl we do
restrict
b1 - b2 = 0
b1 - b3 = 0
end restrict
and get
2 * (lu - lr) = 13.9243
P(Chi-Square(2) > 13.9243 = 0.000947048
Hamilton reports a test statistic of 13.92, so we're on the
money.
Full script:
open hamilton.gdt
genr p = 100*(log(PZUNEW)-log(PZUNEW[1973:01]))
genr pf = 100*(log(PC6IT)-log(PC6IT[1973:01]))
genr s = -100*(log(EXRITL)-log(EXRITL[1973:01]))
# The sample period used by Hamilton
smpl 1974:2 ;
Hamilton <- vecm 12 1 p s pf
restrict Hamilton
b2 = 0
end restrict
restrict Hamilton
b1 + b2 = 0
b1 + b3 = 0
end restrict
--
Allin