[R] regression and dw
Prof Brian Ripley
ripley at stats.ox.ac.uk
Fri Apr 16 18:22:15 CEST 2004
On Fri, 16 Apr 2004, Erin Hodgess wrote:
> Dear R People:
>
> Suppose we have a regression model that we will call
> y.lm
>
> We run the Durbin Watson test for autocorrelation
> and we find that there is positive autocorrelation,
> and phi = 0.72, say.
>
> What is our next step, please?
Look at the residuals more closely, e.g. look at the acf.
> Do we calculate the following
> yprime_t = y_t - 0.72y_t-1,
> x1prime_t = x1_t - 0.72x1_t-1,
>
> and so on, and re-fit the linear mode?
Better to use arima with AR residuals and an xreg matrix.
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-help
mailing list