[R] Estimating parameters of a linear model

vito muggeo vito.muggeo at giustizia.it
Fri Sep 6 12:37:15 CEST 2002


Roughly speaking you have (at least) two way in R:

library(ts)
arima(x, order=c(2,0,2), xreg=y)

library(nlme)
gls(x~y,correlation=corARMA(p=2,q=2))

However if you have just one serie, arima() is faster (in my experience).

Prof. J. Lindsey's libraries (repeated and friends) should allow much more
options (e.g. different distribution), but *as far as I know* these don't
allow immediately direct modelling of MA components. Am I wrong?
Follow the links in R home page

best,
vito



----- Original Message -----
From: "Hagen Schmöller" <Hagen.Schmoeller at iaew.rwth-aachen.de>
To: <r-help at stat.math.ethz.ch>
Sent: Friday, September 06, 2002 8:39 AM
Subject: [R] Estimating parameters of a linear model


Hi R-Community,

I have two correlated time series X[t] and Y[t]. X[t] can be modeled as

X[t] = a[1]X[t-1] + a[2]X[t-2] + e[t] + b[1]e[t-1] + b[2]e[t-2] + c[0]Y[t]

where e[t] is a white noise process. Is there a way to estimate the
coefficients a[1], a[2], b[1], b[2] and c[0]?


Much thanks in advance,

Hagen Schmöller

--
Dipl.-Ing. Hagen K. Schmöller
Institut für Elektrische Anlagen und Energiewirtschaft, RWTH Aachen
Schinkelstraße 6, D-52056 Aachen, Germany
Tel.: +49 (0)241 80-96734
Fax : +49 (0)241 80-92197
Hagen.Schmoeller at iaew.rwth-aachen.de



-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.
-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._.
_._
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list