Function to compute generalized correlation coefficients r*(x|y) and r*(y|x) from two vectors (not matrices)
Function to compute generalized correlation coefficients r*(x|y) and r*(y|x) from two vectors (not matrices)
This function uses the `np' package and assumes that there are no missing data.
gmcxy_np(x, y)
Arguments
x: vector of x data
y: vector of y data
Returns
corxy: r*(x|y) from regressing x on y, where y is the kernel cause.
coryx: r*(y|x) from regressing y on x, where x is the cause.
Note
This is provided if the user want to avoid calling kern.
Examples
## Not run:set.seed(34);x=sample(1:10);y=sample(2:11)gmcxy_np(x,y)## End(Not run)
References
Vinod, H. D. `Generalized Correlation and Kernel Causality with Applications in Development Economics' in Communications in Statistics -Simulation and Computation, 2015, tools:::Rd_expr_doi("10.1080/03610918.2015.1122048")
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.
Author(s)
Prof. H. D. Vinod, Economics Dept., Fordham University, NY