data(sacurine)
attach(sacurine)
for(typeC in c("correlation", "outlier", "overview",
"permutation", "predict-train","predict-test",
"summary", "x-loading", "x-score", "x-variance",
"xy-score", "xy-weight")) {
print(typeC)
if(grepl("predict", typeC))
subset <- "odd"
else
subset <- NULL
opLs <- opls(dataMatrix, sampleMetadata[, "gender"],
predI = ifelse(typeC != "xy-weight", 1, 2),
orthoI = ifelse(typeC != "xy-weight", 1, 0),
permI = ifelse(typeC == "permutation", 10, 0),
subset = subset,
printL = FALSE, plotL = FALSE)
plot(opLs, typeVc = typeC)
}
detach(sacurine)
Run the code above in your browser using DataLab