File: DickeyFullerPValues.Rd

package info (click to toggle)
funitroots 4052.82-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,788 kB
  • sloc: fortran: 509; ansic: 16; makefile: 14
file content (119 lines) | stat: -rw-r--r-- 3,586 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
\name{DickeyFullerPValues}
\alias{DickeyFullerPValues}

\alias{padf}
\alias{qadf}
\alias{adfTable}

\concept{unit root tests}
\concept{distribution of Dickey-Fuller test statistic}
\concept{distribution of augmented Dickey-Fuller test statistic}


\title{Dickey-Fuller p Values}

\description{
    
  A collection and description of functions to compute the distribution
  and quantile function for the ADF unit root test statistics.
    
}

\usage{
padf(q, N = Inf, trend = c("nc", "c", "ct"), statistic = c("t", "n")) 
qadf(p, N = Inf, trend = c("nc", "c", "ct"), statistic = c("t", "n"))

adfTable(trend = c("nc", "c", "ct"), statistic = c("t", "n"), 
    includeInf = TRUE)
}

\arguments{ 
  \item{q}{   
    vector of quantiles or test statistics. Missing values are allowed.
  }
  \item{p}{ 
    vector of probabilities. Missing values are allowed.
  }
  \item{N}{ 
    the number of observations in the sample from which the quantiles
    are to be computed.
  }
  \item{trend}{
    a character string describing the regression from which the
    quantiles are to be computed. Valid choices are: \code{"nc"} for a
    regression with no intercept (constant) nor time trend, \code{"c"}
    for a regression with an intercept (constant) but no time trend, and
    \code{"ct"} for a regression with an intercept (constant) and a time
    trend. The default is \code{"c"}.
  }
  \item{statistic}{ 
    a character string describing the type of test statistic.  Valid
    choices are \code{"t"} for t-statistic and \code{"n"} for normalized
    statistic, sometimes referred to as the rho-statistic. The default
    is \code{"t"}.
  }
  \item{includeInf}{
    a logical flag. Should the asymptotic value be included into the
    table?
  }
}

\details{
  \code{padf} computes cumulative probabilities for the ADF test.
  
  \code{qadf} computes quantiles for the ADF test.

  With sufficiently fine grid for the first argument, \code{padf} and
  \code{qadf} compute, respectively, cumulative distribution functions
  and quantile functions of ADF test statistics.
  
  \code{adfTable}  produces tables of p-values for ADF tests.
}

\value{ 
  for \code{padf} and \code{qadf}, a named numeric vector with attribute
  \code{"control"} holding \code{N},

  for \code{adfTable}, an object from class \code{"gridData"}, which is
  a list with the following components:

  \item{x}{the values of \code{N} (length of the time series) for which
    the statistics are provided,}
  \item{y}{quantiles for which the statistics are provided,}
  \item{Table}{ a matrix with one row for each \code{N} in \code{x} and
    one column for each quantile in \code{y}.}

  The \code{"gridData"} object contains also attribute \code{"control"}
  with information about the requested test.
}

\note{
  \code{padf} and \code{qadf} is based on the tables from A. Banerjee et
  al. (1993). Interpolation is used For value of \code{N} not in the
  tables. For small \code{N} (\code{N < 25}) the result is \code{NA}.
}

\author{
  Diethelm Wuertz for the Rmetrics \R-port.
}
    
\references{ 

Banerjee A., Dolado J.J., Galbraith J.W., Hendry D.F. (1993);
    \emph{Cointegration, Error Correction, and the Econometric 
        Analysis of Non-Stationary Data},
    Oxford University Press, Oxford. 
    
Dickey, D.A., Fuller, W.A. (1979);
    \emph{Distribution of the estimators for autoregressive time 
        series with a unit root}, 
    Journal of the American Statistical Association 74, 427--431. 
}

\examples{
padf(q = -2:2, N = 25)
qadf(p = (1:9)/10, N = 25)
adfTable()
}

\keyword{distribution}