On Sun, 11 Jul 2010, Leigh E. Lommen wrote:


I would like to do the Durban-Watson test on a time series of log returns.
2 questions:
   1) If I am just trying to find out if there is serial correlation,
      what do I do for the residuals?  there is no model, so do I just
      use the log returns (time series) itself?

Test a regression model with an intercept only.

   2) what is the code in R to accomplish this?

There is dwtest() in the "lmtest" package which employs the exact or asymptotic distribution for computing the p-value (both under normality) or durbin.watson() in "car" which employs a bootstrap approach.

Note that there are also various other tests for serial correlation around, e.g., the Breusch-Pagan test in bptest() from "lmtest" among many others.

Best,
Z

Regards

        [[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.


______________________________________________
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.

Reply via email to