ees.ci:

Usage Arguments Examples

Usage

1
ees.ci(x, y, SEED = TRUE, nboot = 400, tr = 0.2, alpha = 0.05, pr = TRUE)

Arguments

x
y
SEED
nboot
tr
alpha
pr

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.

## The function is currently defined as
function (x, y, SEED = TRUE, nboot = 400, tr = 0.2, alpha = 0.05, 
    pr = TRUE) 
{
    if (SEED) 
        set.seed(2)
    x = elimna(x)
    y = elimna(y)
    bvec = 0
    datax <- matrix(sample(x, size = length(x) * nboot, replace = TRUE), 
        nrow = nboot)
    datay <- matrix(sample(y, size = length(x) * nboot, replace = TRUE), 
        nrow = nboot)
    for (i in 1:nboot) {
        bvec[i] = yuenv2(datax[i, ], datay[i, ], tr = tr, SEED = FALSE)$Var.Explained
    }
    bvec <- sort(bvec)
    crit <- alpha/2
    icl <- round(crit * nboot) + 1
    icu <- nboot - icl
    ci <- NA
    ci[1] <- bvec[icl]
    pchk = yuen(x, y, tr = tr)$p.value
    if (pchk > alpha) 
        ci[1] = 0
    ci[2] <- bvec[icu]
    if (ci[1] < 0) 
        ci[1] = 0
    ci = sqrt(ci)
    ci
  }

musto101/wilcox_R documentation built on May 23, 2019, 10:52 a.m.