Augmented Dickey–Fuller test
{{Short description|Time series statistical test}}
In statistics, an augmented Dickey–Fuller test (ADF) tests the null hypothesis that a unit root is present in a time series sample. The alternative hypothesis depends on which version of the test is used, but is usually stationarity or trend-stationarity. It is an augmented version of the Dickey–Fuller test for a larger and more complicated set of time series models.
The augmented Dickey–Fuller (ADF) statistic, used in the test, is a negative number. The more negative it is, the stronger the rejection of the hypothesis that there is a unit root at some level of confidence.{{cite web|url=http://econterms.com/glossary.cgi?action%3D++Search++%26query%3Daugmented+dickey-fuller |title=Glossary of economics research |accessdate=April 2, 2008 |url-status=dead |archiveurl=https://web.archive.org/web/20090302082540/http://econterms.com/glossary.cgi?action=++Search++&query=augmented+dickey-fuller |archivedate=March 2, 2009 }}
Testing procedure
The procedure for the ADF test is the same as for the Dickey–Fuller test but it is applied to the model
:
where is a constant, the coefficient on a time trend and the lag order of the autoregressive process. Imposing the constraints and corresponds to modelling a random walk and using the constraint corresponds to modeling a random walk with a drift. Consequently, there are three main versions of the test, analogous those of the Dickey–Fuller test. (See that article for a discussion on dealing with uncertainty about including the intercept and deterministic time trend terms in the test equation.)
By including lags of the order p, the ADF formulation allows for higher-order autoregressive processes. This means that the lag length p must be determined in order to use the test. One approach to doing this is to test down from high orders and examine the t-values on coefficients. An alternative approach is to examine information criteria such as the Akaike information criterion, Bayesian information criterion or the Hannan–Quinn information criterion.
The unit root test is then carried out under the null hypothesis against the alternative hypothesis of Once a value for the test statistic
:
is computed, it can be compared to the relevant critical value for the Dickey–Fuller test. As this test is asymmetric, we are only concerned with negative values of our test statistic . If the calculated test statistic is less (more negative) than the critical value, then the null hypothesis of is rejected and no unit root is present.
Intuition
The intuition behind the test is that if the series is characterised by a unit root process, then the lagged level of the series () will provide no relevant information in predicting the change in besides the one obtained in the lagged changes (). In this case, the and null hypothesis is not rejected. In contrast, when the process has no unit root, it is stationary and hence exhibits reversion to the mean - so the lagged level will provide relevant information in predicting the change of the series and the null hypothesis of a unit root will be rejected.
Examples
A model that includes a constant and a time trend is estimated using sample of 50 observations and yields the statistic of −4.57. This is more negative than the tabulated critical value of −3.50, so at the 95% level, the null hypothesis of a unit root will be rejected.
class="wikitable" style="text-align: center" | ||||
colspan="5"|Critical values for Dickey–Fuller t-distribution. | ||||
---|---|---|---|---|
colspan="2"|Without trend | colspan="2"|With trend | |||
Sample size | 1% | 5% | 1% | 5% |
T = 25 | −3.75 | −3.00 | −4.38 | −3.60 |
T = 50 | −3.58 | −2.93 | −4.15 | −3.50 |
T = 100 | −3.51 | −2.89 | −4.04 | −3.45 |
T = 250 | −3.46 | −2.88 | −3.99 | −3.43 |
T = 500 | −3.44 | −2.87 | −3.98 | −3.42 |
T = ∞ | −3.43 | −2.86 | −3.96 | −3.41 |
colspan="5"|Source{{cite book |last=Fuller |first=W. A. |year=1976 |title=Introduction to Statistical Time Series |publisher=John Wiley and Sons |location=New York |isbn=0-471-28715-6 }}{{rp|373}} |
Alternatives
There are alternative unit root tests such as the Phillips–Perron test (PP) or the ADF-GLS test procedure (ERS) developed by Elliott, Rothenberg and Stock (1996).{{cite journal |last1=Elliott |first1=G. |last2=Rothenberg |first2=T. J. |first3=J. H. |last3=Stock |year=1996 |title=Efficient Tests for an Autoregressive Unit Root |journal=Econometrica |volume=64 |issue=4 |pages=813–836 |doi=10.2307/2171846 |jstor=2171846 |s2cid=122699512 |url=http://www.nber.org/papers/t0130.pdf }}
Software implementations
- R:
- package
forecast
functionndiffs
{{cite web |title=ndiffs {forecast} {{!}} inside-R {{!}} A Community Site for R |url=http://www.inside-r.org/packages/cran/forecast/docs/ndiffs |archive-url=https://web.archive.org/web/20160717021256/http://www.inside-r.org/packages/cran/forecast/docs/ndiffs |archive-date=2016-07-17 |accessdate=2020-02-23 |website=Inside-r.org}} handles multiple popular unit root tests - package
tseries
functionadf.test
{{cite web|url=http://finzi.psych.upenn.edu/R/library/tseries/html/adf.test.html |title=R: Augmented Dickey-Fuller Test |website=Finzi.psych.upenn.edu |date= |accessdate=2016-06-26}} - package
fUnitRoots
functionadfTest
{{cite web|url=https://fabian-kostadinov.github.io/2015/01/27/comparing-adf-test-functions-in-r/|title=Comparing ADF Test Functions in R · Fabian Kostadinov|website=fabian-kostadinov.github.io|access-date=2016-06-05}} - package
urca
{{Cite web |title=Package 'urca' |url=https://cran.r-project.org/web/packages/urca/urca.pdf}} - Gretl{{cite web|url=http://spot.colorado.edu/~mcnownr/gretl_lab/Introduction-to-gretl-presentation.pdf |title=Introduction to gretl and the gretl instructional lab |website=Spot.colorado.edu |date= |accessdate=2016-06-26}}
- Matlab
- the Econometrics Toolbox{{cite web |date= |title=Econometrics Toolbox - MATLAB |url=http://www.mathworks.com/products/econometrics |accessdate=2016-06-26 |website=Mathworks.com}} function
adfTest
{{cite web|url=http://www.mathworks.com/access/helpdesk/help/toolbox/econ/adftest.html |title=Augmented Dickey-Fuller test - MATLAB adftest |website=Mathworks.com |date= |accessdate=2016-06-26}} - the Spatial Econometrics toolbox{{cite web|url=http://www.spatial-econometrics.com/ |title=Econometrics Toolbox for MATLAB |website=Spatial-econometrics.com |date= |accessdate=2016-06-26}} (free)
- SAS
PROC ARIMA
{{cite web|url=http://www2.sas.com/proceedings/sugi30/192-30.pdf |title=Stationarity Issues in Time Series Models |author=David A. Dickey |website=2.sas.com |accessdate=2016-06-26}} - Stata command
dfuller
{{cite web|url=https://www.stata.com/manuals15/tsdfuller.pdf |title=Augmented Dickey–Fuller unit-root test |website=Stata.com |accessdate=2016-06-26}} - EViews the
Unit Root Test
{{cite web |title=Memento on EViews Output |url=http://www.jonathanbenchimol.com/data/teaching/eviews-training/memento.pdf |accessdate=17 June 2019}}{{cite web|url=http://forums.eviews.com/viewtopic.php?f=18&t=939#p3291 |title=EViews.com • View topic - Dickey Fuller for Multiple Regression Models |website=Forums.eviews.com |date= |accessdate=2016-06-26}}{{cite web|url=http://faculty.smu.edu/tfomby/eco6375/BJ%20Notes/ADF%20Notes.pdf |title=Augmented Dickey-Fuller Unit Root Tests |website=Faculty.smu.edu |date= |accessdate=2016-06-26}}{{cite web|url=http://www.hkbu.edu.hk/~billhung/econ3600/application/app01/app01.html |title=DickeyFuller Unit Root Test |website=Hkbu.edu.hk |date= |accessdate=2016-06-26}} - Python
- package
statsmodels
{{cite web |date= |title=statsmodels.tsa.stattools.adfuller — statsmodels 0.7.0 documentation |url=http://statsmodels.sourceforge.net/devel/generated/statsmodels.tsa.stattools.adfuller.html |accessdate=2016-06-26 |website=Statsmodels.sourceforge.net}} functionadfuller
- package
ARCH
{{Cite web|title=Unit Root Testing — arch 4.19+14.g318309ac documentation|url=https://arch.readthedocs.io/en/latest/unitroot/unitroot_examples.html#Augmented-Dickey-Fuller-Testing|access-date=2021-10-18|website=arch.readthedocs.io}} - Java project
SuanShu
{{cite web |date= |title=SuanShu | Numerical Method Inc |url=http://www.numericalmethod.com/trac/numericalmethod/wiki/SuanShu |url-status=dead |archive-url=https://web.archive.org/web/20150815184906/http://www.numericalmethod.com/trac/numericalmethod/wiki/SuanShu |archive-date=2015-08-15 |accessdate=2016-06-26 |website=Numericalmethod.com}} packagecom.numericalmethod.suanshu.stats.test.timeseries.adf
classAugmentedDickeyFuller
- Julia package
HypothesisTests
{{cite web |title=Time series tests |url=https://juliastats.org/HypothesisTests.jl/latest/time_series/ |accessdate=2020-02-04 |website=juliastats.org}} functionADFTest
See also
References
{{Reflist|30em}}
Further reading
- {{cite book |authorlink=William Greene (economist) |last=Greene |first=W. H. |year=2002 |title=Econometric Analysis |edition=Fifth |publisher=Prentice Hall |location=New Jersey |isbn=0-13-066189-9 }}{{page needed|date=June 2012}}
- {{Cite journal | doi = 10.1093/biomet/71.3.599| title = Testing for Unit Roots in Autoregressive-Moving Average Models of Unknown Order| journal = Biometrika| volume = 71| issue = 3| pages = 599–607| year = 1984| last1 = Said | first1 = S. E. | last2 = Dickey | first2 = D. A. |authorlink2=David Dickey}}
{{DEFAULTSORT:Augmented Dickey-Fuller Test}}