Re: [R] VECM with UNRESTRICTED TREND

From: Grzegorz Konat <grzegorz.konat_at_ibrkk.pl>
Date: Thu, 31 Mar 2011 13:31:35 +0200

Hello Bernhard,

thank You so much one again! Now I (more or less) understand the idea, but still have problem with its practical application.

I do (somewhat following example 8.1 in your textbook):

library(urca)
data(my.data)
names(my.data)
attach(my.data)
dat1 <- my.data[, c("dY", "X", "dM")]
dat2 <- cbind(time)
args('ca.jo')
yxm.vecm <- ca.jo(dat1, type = "trace", ecdet = "trend", K = 2, spec = "longrun", dumvar=dat2)

The above code produces following output:

Error in r[i1, , drop = FALSE] - r[-nrow(r):-(nrow(r) - lag + 1L), , drop = FALSE] :
  non-numeric argument to binary operator

What does that mean? Should I use cbind command to dat1 as well? And doesn't it transform the series into series of integer numbers?

Thank you once again (especially for your patience).

Best,
Greg

2011/3/31 Pfaff, Bernhard Dr. <Bernhard_Pfaff_at_fra.invesco.com>

> Hello Greg,
>
> you include your trend as a (Nx1) matrix and use this for 'dumvar'. The
> matrix 'dumvar' is just added to the VECM as deterministic regressors and
> while you are referring to case 5, this is basically what you are after, if
> I am not mistaken. But we aware that this implies a quadratic trend for the
> levels.
>
> Best,
> Bernhard
>
> ------------------------------
> *Von:* Grzegorz Konat [mailto:grzegorz.konat_at_ibrkk.pl]
> *Gesendet:* Mittwoch, 30. März 2011 20:50
> *An:* Pfaff, Bernhard Dr.; r-help_at_r-project.org
> *Betreff:* Re: [R] VECM with UNRESTRICTED TREND
>
> Hello Bernhard,
>
> Thank You very much. Unfortunately I'm still not really sure how should I
> use dummy vars in this context...
> If I have a system of three variables (x, y, z), lag order = 2 and 1
> cointegrating relation, what should I do? I mean, what kind of 'pattern'
> should be used to create those dummy variables, what should they represent
> and how many of them do I need?
>
> Many thanks in advance!
>
> Best,
> Greg
>
> 2011/3/30 Pfaff, Bernhard Dr. <Bernhard_Pfaff_at_fra.invesco.com>
>
>> Hello Greg,
>>
>> you can exploit the argument 'dumvar' for this. See ?ca.jo
>>
>> Best,
>> Bernhard
>>
>> > -----Ursprüngliche Nachricht-----
>> > Von: r-help-bounces_at_r-project.org
>> > [mailto:r-help-bounces_at_r-project.org] Im Auftrag von Grzegorz Konat
>> > Gesendet: Mittwoch, 30. März 2011 16:46
>> > An: r-help_at_r-project.org
>> > Betreff: [R] VECM with UNRESTRICTED TREND
>> >
>> > Dear All,
>> >
>> > My question is:
>> >
>> > how can I estimate VECM system with "unrestricted trend" (aka
>> > "case 5") option as a deterministic term?
>> >
>> > As far as I know, ca.jo in urca package allows for "restricted trend"
>> > only [vecm
>> > <- ca.jo(data, type = "trace"/"eigen", ecdet = "trend", K =
>> > n, spec = "transitory"/"longrun")].
>> > Obviously, I don't have to do this in urca, so if another
>> > package gives the possibility, please let me know too!
>> >
>> > Thanks in advance!
>> >
>> > Greg
>> >
>> > [[alternative HTML version deleted]]
>> >
>> > ______________________________________________
>> > R-help_at_r-project.org mailing list
>> > https://stat.ethz.ch/mailman/listinfo/r-help
>> > PLEASE do read the posting guide
>> > http://www.R-project.org/posting-guide.html
>> > and provide commented, minimal, self-contained, reproducible code.
>> >
>> *****************************************************************
>> Confidentiality Note: The information contained in this message,
>> and any attachments, may contain confidential and/or privileged
>> material. It is intended solely for the person(s) or entity to
>> which it is addressed. Any review, retransmission, dissemination,
>> or taking of any action in reliance upon this information by
>> persons or entities other than the intended recipient(s) is
>> prohibited. If you received this in error, please contact the
>> sender and delete the material from any computer.
>> *****************************************************************
>>
>>
>

        [[alternative HTML version deleted]]



R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Thu 31 Mar 2011 - 11:35:19 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 31 Mar 2011 - 13:00:26 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive