Learn R Programming

RVAideMemoire (version 0.9-83-7)

spearman.cor.multcomp: Comparison of several Spearman's rank correlation coefficients

Description

Computes Bonferroni-adjusted confidence intervals of a series of Spearman's rank correlation coefficients, for multiple comparisons. Confidence intervals are computed by bootstraping.

Usage

spearman.cor.multcomp(var1, var2, fact, alpha = 0.05, nrep = 1000)

Value

method

name of the test.

data.name

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

tab

data frame of correlation coefficients with confidence intervals

alpha

significance level.

nrep

number of replicates for bootstraping.

Arguments

var1

numeric vector (first variable).

var2

numeric vector (second variable).

fact

factor (groups).

alpha

significance level.

nrep

number of replicates for bootstraping.

Author

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

Details

Confidence intervals which do not overlap indicate correlation coefficients significantly different at alpha.

See Also

spearman.ci

Examples

Run this code
set.seed(1510)
var1 <- c(1:15+rnorm(15,0,2),1:15+rnorm(15,0,2),1:15+rnorm(15,0,2))
var2 <- c(-1:-15+rnorm(15,0,2),1:15+rnorm(15,0,2),1:15+rnorm(15,0,2))
fact <- gl(3,15,labels=LETTERS[1:3])
spearman.cor.multcomp(var1,var2,fact)
# B and C similar but different from A

Run the code above in your browser using DataLab