cor.one {tinyarray} | R Documentation |
cor.test for one variable with all variables
Description
cor.test for all variables(each two columns)
Usage
cor.one(
x,
var,
drop.var = min(x[, var]) - 0.001,
drop.other = min(x[, -which(colnames(x) == var)]) - 0.001,
min.obs = 10
)
Arguments
x |
A numeric matrix or data.frame |
var |
your chosen variable,only one. |
drop.var |
drop values in var |
drop.other |
drop values in other columns |
min.obs |
minimum number of observations after dropping |
Value
A data.frame with cor.test p.value and estimate
Author(s)
Xiaojie Sun
See Also
Examples
x = iris[,-5]
cor.one(x,"Sepal.Width")
[Package tinyarray version 2.4.2 Index]