spearman.ci: Confidence interval of a Spearman's rank correlation...

Description Usage Arguments Value Author(s) See Also Examples

View source: R/spearman.ci.R

Description

Computes the confidence interval of a Spearman's rank correlation coefficient by bootstraping.

Usage

1
spearman.ci(var1, var2, nrep = 1000, conf.level = 0.95)

Arguments

var1

numeric vector (first variable).

var2

nuermic verctor (second variable).

nrep

number of replicates for bootstraping.

conf.level

confidence level of the interval.

Value

method

name of the test.

data.name

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

conf.level

confidence level.

rep

number of replicates.

estimate

Spearman's rank correlation coefficient.

conf.int

confidence interval.

Author(s)

Maxime Herv<e9> <[email protected]>

See Also

cor.test, boot

Examples

1
2
3
var1 <- sample(1:50,15,replace=TRUE)
var2 <- sample(1:50,15,replace=TRUE)
spearman.ci(var1,var2)

Example output

*** Package RVAideMemoire v 0.9-68 ***

	Spearman's rank correlation

data:  var1 and var2
1000 replicates

95 percent confidence interval:
 -0.1217231  0.8087646
sample estimates:
      rho 
0.4955149 

RVAideMemoire documentation built on Aug. 21, 2017, 5:07 p.m.