[R-SIG-Finance] How to automatically extract test result from Johansen test?
R. Michael Weylandt
michael.weylandt at gmail.com
Fri Mar 30 18:08:25 CEST 2012
Actually, it looks like ca.jo objects are S4 so it's a little bit
harder: take a look at ?`ca.jo-class` (note the backticks) to see the
26 slots available. I'm not sure if the ones you want have dedicated
extractor methods but you can get them with ?slot directly. There's
not an absolute pass/fail (like most other statistical tests) so you
have to pick your desired significance threshold, but that's not hard.
As Brian said though, it makes most sense to do this inside your loop
construction.
Hope this helps,
Michael Weylandt
On Fri, Mar 30, 2012 at 12:00 PM, Brian G. Peterson <brian at braverock.com> wrote:
> On Fri, 2012-03-30 at 10:53 -0500, Michael wrote:
>> How to automatically extract test result from Johansen test?
>>
>> Hi all,
>>
>> I am using the "ca.jo" function to do the Johansen test.
>>
>> It's outputting a lot of results.
>>
>> If I am running this on a large number of assets, is there a way to
>> automatically extract and condense the test outputs to just "pass/fail" and
>> "residuals"?
>>
>> Thanks a lot!
>
> Like all R objects, it is a list internally. Extract what you need in
> the same loop that's doing the test.
>
> Please at least try before posting.
>
> --
> Brian G. Peterson
> http://braverock.com/brian/
> Ph: 773-459-4973
> IM: bgpbraverock
>
> _______________________________________________
> R-SIG-Finance at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-sig-finance
> -- Subscriber-posting only. If you want to post, subscribe first.
> -- Also note that this is not the r-help list where general R questions should go.
More information about the R-SIG-Finance
mailing list