Uses row-wise permutation of the Y block to assess the significance of each
latent variable (LV) in a fitted plsc model. The test statistic is the
singular value of the cross-covariance matrix for each LV.
# S3 method for plsc
perm_test(
x,
X,
Y,
nperm = 1000,
comps = ncomp(x),
stepwise = TRUE,
shuffle_fun = NULL,
parallel = FALSE,
alternative = c("greater", "less", "two.sided"),
alpha = 0.05,
...
)A fitted plsc model object.
Original X block used to fit x.
Original Y block used to fit x.
Number of permutations to perform (default 1000).
Number of components (LVs) to test. Defaults to ncomp(x).
Logical; if TRUE (default), perform sequential testing with deflation.
Optional function to permute Y; defaults to shuffling rows.
Logical; if TRUE, use parallel processing via future.apply.
Character string for the alternative hypothesis: "greater" (default), "less", or "two.sided".
Significance level used to report n_significant; not used
directly in p-value calculation.
Additional arguments (currently unused).