bootstrap.SEPaLS {SEPaLS} | R Documentation |
Bootstrap function for SEPaLS estimator.
Description
Bootstrap function for SEPaLS estimator.
Usage
bootstrap.SEPaLS(
X,
Y,
yn,
type = c("vMF", "Laplace"),
mu0 = NULL,
kappa0 = NULL,
lambda = NULL,
B = 20
)
Arguments
X |
|
Y |
|
yn |
|
type |
character, whether |
mu0 |
|
kappa0 |
|
lambda |
|
B |
positive integer. The number of bootstrap samples on which estimate the SEPaLS directions. Default to 20. |
Value
A list with two elements:
-
ws
: A-dimensional matrix with each row corresponding to the SEPaLS direction estimated on each bootstrap sample.
-
cor
: The correlation of each estimate direction on the Out-Of-Bag (OOB) sample with the response.
See Also
Examples
set.seed(5)
n <- 3000
p <- 10
X <- matrix(rnorm(n*p),n,p)
beta <- c(5:1,rep(0,p-5)) ; beta <- beta/sqrt(sum(beta^2))
Y <- (X%*%beta)^3 + rnorm(n)
boot.sepals_Laplace <- bootstrap.SEPaLS(X,Y,yn=1,type="Laplace",lambda=0.01,
B=100)
boxplot(boot.sepals_Laplace$ws);abline(h=0,col="red",lty=2)