Learn R Programming

dcov (version 0.1.1)

pdcov: Partial distance covariance

Description

This method implements the method to compute the value of partial distance covariance proposed by Sz<U+00E9>kely and Rizzo, 2014.

Usage

pdcov(x, y, z, type = c("U", "V"))

pdcor(x, y, z, type = c("U", "V"))

Arguments

x

the matrix of x

y

the matrix of y

z

the matrix of z. Given the value of z, pdcov or pdcor between x and y is calcuated.

type

"V" or "U", for V- or U-statistics of partial distance covariance or correlation. The default value is "U".

References

Sz<U+00E9>kely, G. J., & Rizzo, M. L. (2014). Partial distance correlation with methods for dissimilarities. The Annals of Statistics, 42(6), 2382-2412.

Examples

Run this code
# NOT RUN {
z = matrix(rnorm(400),200,2)
x = matrix(rnorm(400),200,2)*z
y = matrix(rnorm(400),200,2)*z
pdcov(x,y,z)
pdcor(x,y,z)

# }

Run the code above in your browser using DataLab