stats/
dw_critical.pro
topdw_critical
stats
result = dw_critical(sig, reg, n)
return the critical values for the Durbin-Watson test statistic from http://www.tau.ac.il/~yonar/econometrics/durbinwatson.pdf
Return value
an array with the [lower, upper] bounds of the test statistic
Parameters
- sig in required
sigificance level (1%, 2.5%, 5%)
- reg in required
number of regressors (2,3,4,5,6)
- n in required
number of data pairs, 15 to 100 rounded to array
Examples
see
http://people.bu.edu/balarsen/Home/IDL/Entries/2007/12/1_Durbin-Watson_test_for_autocorrelation.html
IDL> print, dw_critical(1, 2, 23)
1.01700 1.18600
IDL> print, dw_critical(1, 2, 51)
1.32400 1.40300
IDL> print, dw_critical(1, 2, 101)
1.52200 1.56200
IDL> print, dw_critical(1, 2, 100)
1.52200 1.56200
IDL> print, dw_critical(1, 2, 36)
1.20500 1.31500
Author information
- History:
Mon Jan 7 16:25:00 2008, Brian Larsen updated for new round2array() inputs Sat Dec 1 12:39:06 2007, Brian Larsen written and tested
Statistics
| Lines: | 189 |
| McCabe complexity: |
File attributes
| Modifcation date: | Mon Sep 22 12:40:45 2008 |
| Lines: | 238 |
![[attach.png]](../idldoc-resources/attach.png)