perm.cor.test: Permutation Pearson's correlation test

View source: R/perm.cor.test.R

perm.cor.testR Documentation

Permutation Pearson's correlation test

Description

Performs a permutation Pearson's product-moment correlation test.

Usage

perm.cor.test(x, y, alternative = c("two.sided", "less", "greater"),
  nperm = 999, progress = TRUE)

Arguments

x, y

numeric vectors of data values. x and y must have the same length.

alternative

a character string specifying the alternative hypothesis, must be one of "two.sided" (default), "greater" or "less".

nperm

number of permutations.

progress

logical indicating if the progress bar should be displayed.

Details

The function deals with the limitted floating point precision, which can bias calculation of p-values based on a discrete test statistic distribution.

Value

method

name of the test.

data.name

a character string giving the name(s) of the data.

statistic

test statistics of the parametric test.

permutations

number of permutations.

p.value

p-value of the permutation test.

estimate

the estimated correlation coefficient.

alternative

a character string describing the alternative hypothesis.

null.value

the value of the association measure under the null hypothesis, always 0.

Author(s)

Maxime HERVE <maxime.herve@univ-rennes1.fr>

See Also

cor.test

Examples

x <- rnorm(50)
y <- runif(50)
perm.cor.test(x,y)

RVAideMemoire documentation built on Nov. 6, 2023, 5:07 p.m.