Skip to content
Back to formatted view

Raw Message

Message-ID: <7acc7a990911012027q8a1004fw532de6847d3dc9ee@mail.gmail.com>
Date: 2009-11-02T04:27:14Z
From: Erin Hodgess
Subject: using exists with coef from an arima fit

Dear R People:

I have the output from an arima model fit in an object xxx.

I want to verify that the ma1 coefficient is there, so I did the following:
> xxx$coef
       ar1        ar2        ma1  intercept
 1.3841297 -0.4985667 -0.9999996 -0.1091657
> str(xxx$coef)
 Named num [1:4] 1.384 -0.499 -1 -0.109
 - attr(*, "names")= chr [1:4] "ar1" "ar2" "ma1" "intercept"
> exists('xxx$coef["ma1"]')
[1] FALSE
>

Other than using xxx$coef[3], is there another way to check this, please?

Thanks in advance,
Sincerely,
Erin


-- 
Erin Hodgess
Associate Professor
Department of Computer and Mathematical Sciences
University of Houston - Downtown
mailto: erinm.hodgess at gmail.com