rstar: Function to compute generalized correlation coefficients...

Description Usage Arguments Value Note Author(s) References See Also Examples

View source: R/rstar.R

Description

Uses Vinod (2015) definition of generalized (asymmetric) correlation coefficients. It requires kernel regression of x on y obtained by using the ‘np’ package. It also reports usual Pearson correlation coefficient r and p-value for testing the null hypothesis that (population r)=0.

Usage

1
rstar(x, y)

Arguments

x

Vector of data on the dependent variable

y

Vector of data on the regressor

Value

Four objects created by this function are:

corxy

r*x|y or regressing x on y

coryx

r*y|x or regressing y on x

pearson.r

Pearson's product moment correlation coefficient

pv

The p-value for testing the Pearson r

Note

This function needs the kern function which in turn needs the np package.

Author(s)

Prof. H. D. Vinod, Economics Dept., Fordham University, NY

References

Vinod, H. D. 'Generalized Correlation and Kernel Causality with Applications in Development Economics' in Communications in Statistics -Simulation and Computation, 2015, https://doi.org/gffn86

Vinod, H. D. 'Matrix Algebra Topics in Statistics and Economics Using R', Chapter 4 in Handbook of Statistics: Computational Statistics with R, Vol.32, co-editors: M. B. Rao and C.R. Rao. New York: North Holland, Elsevier Science Publishers, 2014, pp. 143-176.

See Also

See Also gmcmtx0 and gmcmtxBlk.

Examples

1
x=sample(1:30);y=sample(1:30); rstar(x,y)

generalCorr documentation built on Jan. 4, 2022, 1:08 a.m.