Durbin-Watson
Durbin-Watson statistic is related auto-correlation. After we run a regression, the error term should have no correlation, with a mean zero. Durbin-Watson statistic is defined as:
Here, et is the error term at time t, T is the total number of error term. The Durbin-Watson statistic tests the null hypothesis that the residuals from an ordinary least-squares regression are not auto-correlated against the alternative that the residuals follow an AR1 process. The Durbin-Watson statistic ranges in value from 0 to 4. A value near 2 indicates non-autocorrelation; a value toward 0 indicates positive autocorrelation; a value toward 4 indicates negative autocorrelation, see the following table:
Durbin-Watson Test |
Description |
---|---|
No autocorrelation | |
Towards 0 |
Positive auto-correlation |
Towards 4 |
Negative auto-correlation |
Table 8.3 Durbin-Watson Test
The following Python program runs a CAPM first by using daily data for IBM. The S&P500 is used as the index. The time period is from...