Skip to content
Prev 361826 / 398506 Next

extracting coefficients from ar() output

Thank you very much, Peter. I played a bit and found a solution.
[1] 0.9430692 0.9140253 0.9236898 0.9426744 0.9465110 0.9318470 0.9033054 0.9206048 0.9243736 0.9129082
[11] 0.9181811 0.9350779 0.9464205 0.9410245 0.9335568 0.9201928 0.8869414 0.8320984 0.8185671 0.7989182
[21] 0.7454876 0.6388364 0.6797046 0.6704642 0.7077033 0.8895698 0.8755445 0.8965050 0.8969068 0.8891385
[31] 0.9284835 0.9628297 0.9674624 0.9524462 0.9423693 0.9629843 0.9996613 1.0000295 0.9845222 0.9877242
[41] 0.9582863 0.9596756 0.9415847 0.9471677 0.9447052 0.9324048 0.9171082 0.8928825 0.9133751 0.9203662

I am trying to export the data to Excel using WriteXLS:
Unfortunately, it doesn't work. How can I export the data to Excel?

-----Original Message-----
From: peter dalgaard [mailto:pdalgd at gmail.com] 
Sent: 16 June 2016 18:49
To: William Dunlap
Cc: T.Riedle; R-help at r-project.org
Subject: Re: [R] extracting coefficients from ar() output
Also notice that the output of rollapply is not an ar object. More likely a list of them, so  try rollingarma[[i]]$ar or maybe lapply(rollingarma, function(x)x$ar) or sapply(rollingarma, "[[", "ar") or...
--
Peter Dalgaard, Professor,
Center for Statistics, Copenhagen Business School Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Office: A 4.23
Email: pd.mes at cbs.dk  Priv: PDalgd at gmail.com