permcor: Permutation based p-value for the Pearson correlation...

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

Description

Permutation based p-value for the Pearson correlation coefficient.

Usage

1
permcor(x, y, R = 999) 

Arguments

x

A numerical vector with the first variable.

y

A numerical vector with the second variable.

R

The number of permutations to be conducted; set to 999 by default.

Details

This is a very low computational calculation of the p-value. Try it yourselves.

Value

A vector consisting of two values, the Pearson correlation and the permutation based p-value.

Author(s)

Marios Dimitriadis and Michail Tsagris

R implementation and documentation: Marios Dimitriadis and Michail Tsagris <kmdimitriadis@gmail.com> and <mtsagris@csd.uoc.gr>

References

Chatzipantsiou C., Dimitriadis M., Papadakis M. and Tsagris M. (2019). Extremely efficient permutation and bootstrap hypothesis tests using R. To appear in the Journal of Modern Applied Statistical Methods.

https://arxiv.org/ftp/arxiv/papers/1806/1806.10947.pdf

See Also

pc.skel

Examples

1
2
3
4
x <- iris[, 1]
y <- iris[, 2]
res<-permcor(x, y)
res<-permcor(x, y, R = 9999)

Rfast documentation built on Dec. 11, 2021, 9:59 a.m.