1 |
x |
|
est |
|
alpha |
|
grp |
|
nboot |
|
... |
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 | ##---- 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, est = onestep, alpha = 0.05, grp = NA, nboot = NA,
...)
{
if (!is.list(x) && !is.matrix(x)) {
stop("Data must be stored in a matrix or in list mode.")
}
if (is.list(x)) {
mat <- matrix(0, length(x[[1]]), length(x))
for (j in 1:length(x)) mat[, j] <- x[[j]]
}
if (is.matrix(x))
mat <- x
mat <- elimna(mat)
J <- ncol(mat)
Jm <- J - 1
con <- matrix(0, ncol = Jm, nrow = J)
for (j in 1:Jm) {
jp <- j + 1
for (k in j:jp) {
con[j, j] <- 1
con[jp, j] <- 0 - 1
}
}
rmmcp(x, est = est, alpha = alpha, con = con, nboot = nboot,
...)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.