dCovTS (version 1.1)

ADCV: Auto-distance Covariance Function

Description

Computes the auto-distance covariance function of a univariate time series. It also computes the unbiased estimator of squared auto-distance covariance.

Usage

ADCV(x, MaxLag = 15, unbiased = FALSE)

Arguments

x

numeric vector or univariate time series.

MaxLag

maximum lag order at which to calculate the ADCV. Default is 15.

unbiased

logical value. If unbiased = TRUE, the unbiased estimator of squared auto-distance covariance is returned. Default value is FALSE.

Value

Returns a vector, whose length is determined by MaxLag, and contains the biased estimator of ADCV or the unbiased estimator of squared ADCV.

Details

Szekely et al. (2007) recently proposed distance covariance function between two random vectors. Zhou (2012) extended this measure of dependence to a time series framework by calling it auto-distance covariance function.

ADCV computes the sample auto-distance covariance function, \(V_X(\cdot)\), between \(\{X_t\}\) and \(\{X_{t+j}\}\). Formal definition of \(V_X(\cdot)\) can be found in Zhou (2012) and Fokianos and Pitsillou (2016).

The empirical auto-distance covariance function, \(\hat{V}_X(\cdot)\), is the non-negative square root defined by $$ \hat{V}_X^2(j) = \frac{1}{(n-j)^2}\sum_{r,l=1+j}^{n}{A_{rl}B_{rl}}, \quad 0 \leq j \leq (n-1)$$

and \(\hat{V}_X^2(j) = \hat{V}_X^2(-j)\), for \(-(n-1) \leq j < 0\), where \(A=A_{rl}\) and \(B=B_{rl}\) are Euclidean distances with elements given by $$ A_{rl} = a_{rl} - \bar{a}_{r.} - \bar{a}_{.l} + \bar{a}_{..} $$ with \(a_{rl}=|X_r-X_l|\), \(\bar{a}_{r.}=\Bigl(\sum_{l=1+j}^{n}{a_{rl}}\Bigr)/(n-j)\), \(\bar{a}_{.l}=\Bigl(\sum_{r=1+j}^{n}{a_{rl}}\Bigr)/(n-j)\) , \(\bar{a}_{..}=\Bigl(\sum_{r,l=1+j}^{n}{a_{rl}}\Bigr)/(n-j)^2\). \(B_{rl}\) is given analogously based on \(b_{rl}=|Y_r-Y_l|\), where \(Y_t=X_{t+j}\). \(X_t\) and \(X_{t+j}\) are independent if and only if \(V_X^2(j)=0\). See Fokianos and Pitsillou (2016) for more information on theoretical properties of \(V_X^2(\cdot)\) including consistency.

If unbiased = TRUE, ADCV returns the unbiased estimator of squared auto-distance covariance function, \(\tilde{V}_X^2(j)\), proposed by Szekely and Rizzo (2014). In the context of time series data, this is given by $$ \tilde{V}_X^2(j) = \frac{1}{(n-j)(n-j-3)}\sum_{r\neq l}{\tilde{A}_{rl}\tilde{B}_{rl}}, $$ for \(n > 3\), where \(\tilde{A}_{rl}\) is the \((r,l)\) element of the so-called U-centered matrix \(\tilde{A}\), defined by $$ \tilde{A}_{rl} = \frac{1}{n-j-2}\sum_{t=1+j}^{n}{a_{rt}}-\frac{1}{n-j-2}\sum_{s=1+j}^{n}{a_{sl}+\frac{1}{(n-j-1)(n-j-2)}\sum_{t,s=1+j}^{n}{a_{ts}}}, \quad i \neq j, $$ with zero diagonal.

mADCV gives the auto-distance covariance function of a multivariate time series.

References

Fokianos K. and M. Pitsillou (2016). Consistent testing for pairwise dependence in time series. Technometrics, http://dx.doi.org/10.1080/00401706.2016.1156024.

Szekely, G. J. and M. L. Rizzo (2014). Partial distance correlation with methods for dissimilarities. The Annals of Statistics \(\textbf{42}\), 2382-2412, dx.doi.org/10.1214/14-AOS1255.

Szekely, G. J., M. L. Rizzo and N. K. Bakirov (2007). Measuring and testing dependence by correlation of distances. The Annals of Statistics \(\textbf{35}\), 2769-2794, http://dx.doi.org/10.1214/009053607000000505.

Zhou, Z. (2012). Measuring nonlinear dependence in time series, a distance correlation approach. Journal of Time Series Analysis \(\textbf{33}\), 438-457, http://dx.doi.org/10.1111/j.1467-9892.2011.00780.x.

See Also

ADCF, mADCV

Examples

Run this code
# NOT RUN {
x <- rnorm(500)
ADCV(x,18) 

ADCV(BJsales,25)
# }

Run the code above in your browser using DataLab