Durbin's h Test Calculator
Inputs
- Inputs: Durbin-Watson d 1.65, sample size 100, variance of the lagged dependent variable's coefficient 0.0004.
- Implied autocorrelation rho = 1 - d/2 = 0.1750; the correction term is 1 - n Var(b) = 0.9600.
- h = rho x sqrt(n / (1 - n Var(b))) = 1.7861, standard normal under the null of no autocorrelation.
- The two-sided p-value is 0.0741.
The Durbin-Watson statistic is the first thing an econometrician reaches for when residuals might be autocorrelated - unless the regression contains a lagged dependent variable, in which case Durbin-Watson is biased toward 2 and will smile on autocorrelated residuals. Durbin's h is the repair he published in 1970 for exactly that case. This calculator builds h from the Durbin-Watson statistic you already have, the sample size, and the estimated variance of the lagged dependent variable's coefficient, and returns the statistic with its standard-normal p-value.
Worked examples
Mild positive autocorrelation
(1.65 · 100 · 0.0004)
| Durbin's h statistic | 1.7861 |
| Implied lag-1 autocorrelation rho | 0.1750 |
| Two-sided p-value | 0.0741 |
| Denominator term 1 - n Var(b) | 0.9600 |
Strong autocorrelation, small sample
(1.2 · 60 · 0.001)
| Durbin's h statistic | 3.1957 |
| Implied lag-1 autocorrelation rho | 0.4000 |
| Two-sided p-value | 0.0014 |
| Denominator term 1 - n Var(b) | 0.9400 |
Slight negative autocorrelation
(2.1 · 250 · 0.0002)
| Durbin's h statistic | -0.8111 |
| Implied lag-1 autocorrelation rho | -0.0500 |
| Two-sided p-value | 0.4173 |
| Denominator term 1 - n Var(b) | 0.9500 |
Why Durbin-Watson fails with lagged outcomes
A lagged dependent variable changes what the residuals can look like. When this period's outcome sits on the right-hand side of next period's equation, the regressor is correlated with the error term by construction, and the ordinary Durbin-Watson statistic is pulled toward its no-autocorrelation value of 2 whether or not the errors are truly clean. Durbin showed the bias in 1970 and supplied two remedies: the h test on this page, which rescues the Durbin-Watson statistic with a variance correction, and an alternative regression-based procedure for the cases where h cannot be computed.
The setting is everywhere in applied work. Wage equations with last year's wage, consumption with last year's consumption, regional growth with last year's income - dynamic panels and time-series regressions are built from lagged outcomes. Every one of them invalidates the textbook Durbin-Watson table, and every one of them is the h test's home ground. The inputs are deliberately the ones such a regression already reports: its Durbin-Watson statistic, its sample size, and the variance of one coefficient from its own covariance matrix.
- Built for regressions with a lagged dependent variable
- Rescues the Durbin-Watson statistic with a variance correction
- Standard normal under the null of no autocorrelation
- Undefined when n times the coefficient variance reaches 1
From d to rho
The bridge between the two statistics is the implied first-order autocorrelation, rho = 1 - d/2. A Durbin-Watson of 2 means rho of zero; the first example's d of 1.65 implies rho of 0.1750, and the second example's 1.20 implies a hefty 0.4000. The third example runs the other way: d of 2.10 implies rho of -0.0500, mild negative autocorrelation, and its h comes out negative at -0.8111. The sign is carried through deliberately - h is a two-sided test, and negative autocorrelation, the signature of over-differencing, is a finding in its own right.
Rho alone is not the test, because the same rho means different things at different precisions. What h adds is the sampling theory: it divides rho by its standard error under the null, and that standard error is where the lagged coefficient's variance enters. A precisely estimated dynamic coefficient makes rho's own estimate trustworthy and the test sharp; a sloppy one widens the null distribution and the same rho stops being evidence.
Worked examples
Example 1: Durbin-Watson statistic d 1.65; Sample size n 100; Variance of lagged dependent coefficient 0.0004. Durbin's h statistic = 1.7861. Supporting values: Implied lag-1 autocorrelation rho 0.1750; Two-sided p-value 0.0741; Denominator term 1 - n Var(b) 0.9600. Inputs: Durbin-Watson d 1.65, sample size 100, variance of the lagged dependent variable's coefficient 0.0004. Implied autocorrelation rho = 1 - d/2 = 0.1750; the correction term is 1 - n Var(b) = 0.9600. h = rho x sqrt(n / (1 - n Var(b))) = 1.7861, standard normal under the null of no autocorrelation. The two-sided p-value is 0.0741.
Example 2: Durbin-Watson statistic d 1.2; Sample size n 60; Variance of lagged dependent coefficient 0.001. Durbin's h statistic = 3.1957. Supporting values: Implied lag-1 autocorrelation rho 0.4000; Two-sided p-value 0.0014; Denominator term 1 - n Var(b) 0.9400. Inputs: Durbin-Watson d 1.20, sample size 60, variance of the lagged dependent variable's coefficient 0.0010. Implied autocorrelation rho = 1 - d/2 = 0.4000; the correction term is 1 - n Var(b) = 0.9400. h = rho x sqrt(n / (1 - n Var(b))) = 3.1957, standard normal under the null of no autocorrelation. The two-sided p-value is 0.0014.
Example 3: Durbin-Watson statistic d 2.1; Sample size n 250; Variance of lagged dependent coefficient 0.0002. Durbin's h statistic = -0.8111. Supporting values: Implied lag-1 autocorrelation rho -0.0500; Two-sided p-value 0.4173; Denominator term 1 - n Var(b) 0.9500. Inputs: Durbin-Watson d 2.10, sample size 250, variance of the lagged dependent variable's coefficient 0.0002. Implied autocorrelation rho = 1 - d/2 = -0.0500; the correction term is 1 - n Var(b) = 0.9500. h = rho x sqrt(n / (1 - n Var(b))) = -0.8111, standard normal under the null of no autocorrelation. The two-sided p-value is 0.4173.
The variance correction
The standard error is built from the term 1 - n Var(b), where b is the coefficient on the lagged dependent variable. In the first example the variance is 0.0004 at a sample size of 100, so the term is 0.9600 and the correction is gentle. In the second example a variance of 0.0010 at 60 observations gives 0.9400. The term is doing conceptual work beyond its size: it prices how much of the apparent autocorrelation could be an artefact of estimating the dynamics themselves, which is exactly the bias that ruins the uncorrected statistic.
The term also marks the test's boundary. If n Var(b) reaches or exceeds 1, the quantity under the square root turns negative and h does not exist. That is not a calculator limitation - it is Durbin's own result, and his paper supplies the alternative procedure for that case: regress the residuals on the original regressors plus the lagged residuals and test the added term. A well-designed dynamic regression rarely lands near the boundary, because it means the lagged coefficient is estimated so loosely that the equation's dynamics are barely identified at all.
Reading h and its p-value
Under the null, h is standard normal, so the familiar landmarks apply: beyond about 2 in absolute value, the two-sided p-value falls under 0.05. The first example's h of 1.7861 gives a p-value of 0.0741 - suggestive of the positive autocorrelation its rho of 0.1750 advertises, short of decisive. The second example is decisive: h of 3.1957 and a p-value of 0.0014 leave little doubt that the errors are autocorrelated, and the model's standard errors - computed as if they were not - are not to be trusted until the dynamics are respecified.
The third example is the quiet case done properly: h of -0.8111, p-value 0.4173, no evidence against the null in either direction. Reporting that result matters as much as reporting a rejection, because a dynamic specification that survives the h test has earned the right to have its standard errors read at face value. The test is cheap, its inputs are already on the regression output, and skipping it leaves the most common specification error in dynamic work unexamined.
Durbin's alternative procedure, for the cases where h fails, deserves its sentence: regress the residuals on the full set of original regressors plus the lagged residuals, and test the lagged-residual coefficient. It is asymptotically equivalent to h, it always exists, and it generalises - with several lags of residuals it becomes a portmanteau check in the spirit of Breusch-Godfrey. The h test survives alongside it because it asks for nothing the regression has not already printed: one statistic from the output, one variance from the covariance matrix, one sample size.
In panel settings the same logic follows the data. Dynamic panels - outcomes regressed on their own lags across many individuals - are where lagged dependent variables do their most consequential modern work, and where residual autocorrelation quietly invalidates the standard instruments. The h test was built for a single time series, and panel practice has its own dedicated tests, but the intellectual move is Durbin's: never read a Durbin-Watson statistic at face value when the outcome's own past is sitting among the regressors.
The test's economy is worth a final word. It asks the regression for nothing it has not already produced, it states its answer on the standard normal scale every economist reads fluently, and it fails loudly - by ceasing to exist - exactly when its own assumptions give out. Instruments that honest about their limits tend to stay in use, and this one has, for over fifty years.
When h cannot be computed
Beyond the boundary case, the h test has the usual limits of a test built for first-order autocorrelation in a single equation. It says nothing about higher-order correlation - a process quiet at lag one and loud at lag four passes it - and nothing about autocorrelation induced by an omitted variable or a wrong functional form, both of which it will detect without diagnosing. The Breusch-Godfrey test, which handles higher orders and general regressors, is the natural next step and has its own page on this site; the h test remains the quickest check aimed precisely at the lagged-dependent-variable problem.
Used in its jurisdiction, though, it is exactly the right instrument: one number that corrects the statistic every package prints anyway, by the amount the package's own covariance matrix says is needed. Durbin built it in 1970 out of parts the regression already had, and dynamic regressions have been quietly depending on it ever since.
FAQs
What h statistic does the first worked example give?
1.7861, from a Durbin-Watson of 1.65 at 100 observations with a lagged-coefficient variance of 0.0004.
What p-value does the first example give?
0.0741 - suggestive of positive autocorrelation, short of the conventional line.
What implied autocorrelation does the first example have?
0.1750, from rho = 1 - d/2 with d of 1.65.
What is the denominator term in the second example?
0.9400: one minus 60 times the variance of 0.0010.
What h does the strongly autocorrelated second example give?
3.1957, with a p-value of 0.0014 - decisive evidence against the null.
What h does the slightly negative third example give?
-0.8111. A Durbin-Watson of 2.10 implies rho of -0.0500, and the test is two-sided.