1 |
x |
|
y |
|
itest |
|
sm.fun |
|
nboot |
|
alpha |
|
SEED |
|
fr |
|
plot.fun |
|
plotit |
|
... |
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 | ##---- 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, itest = 1, sm.fun = rplot, nboot = 500, alpha = 0.05,
SEED = TRUE, fr = 1, plot.fun = rplot, plotit = TRUE, ...)
{
if (!is.matrix(x))
stop("Should have two or more predictors stored in a matrix")
p <- ncol(x)
pp <- p + 1
x <- elimna(cbind(x, y))
y <- x[, pp]
x <- x[, 1:p]
flag <- rep(T, ncol(x))
flag[itest] <- F
temp <- sm.fun(x[, flag], y, plotit = FALSE, pyhat = TRUE,
fr = fr)
res <- y - temp
test.it <- indt(x[, itest], res)
if (plotit)
plot.fun(x[, itest], res, ...)
test.it
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.