Use the arima function with the xreg option that is a vector or matrix of
external regressors. Use AIC or BIC when identifying the error process.

Hannu

On Thu, Mar 20, 2008 at 5:54 PM, bereket weldeslassie <berekket@gmail.com>
wrote:

>  Hi Everyone,
> One more information to my question. I am trying to do a time series
> regression using the lm function. *My intention is to investigate the
> relationship between a dependent time series variable and several
> independent time series variables.* According to the durbin watson test
> the
> errors are autocorrelated. And then I tried to use the gls function to
> accomodate for the autocorrelated errors. My question is how do I know
> what
> ARMA process (order) to use in the gls function? Or is there any other way
> to do the time series regression in R? I highly appreciate your help.
> Thanks,
> Bereket
>
>        [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help@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.
>

	[[alternative HTML version deleted]]

