capr.boot: Bootstrap confidence intervals for CAP coefficients
Description
Generates bootstrap inference for the CAP regression coefficients while
holding the fitted directions \(\Gamma\) fixed. Each replicate samples the
covariance slices \(S[, , i]\) with replacement, projects them onto the fixed
directions to obtain component-specific variances, and re-solves the
\(\beta^{(k)}\) equations. Quantile-based confidence intervals are returned
for every predictor/component pair.
simu.data <- simu.capr(seed = 123L, n = 120L)
K <- 3L
fit <- capr(
S = simu.data$S,
X = simu.data$X,
K = K
)
capr.boot(fit, nboot = 10L, level = 0.95, seed = 42L)