## Loading the first dataset
data(batch.dat)
## Fitting the optimal ANCOVA model to the data gives:
fit <- svpls(10,10,batch.dat,pmax = 5)
## The optimal ANCOVA model, its AIC value and the positive genes detected from it are given by:
fit$opt.model
fit$AIC.opt
fit$genes
## The corrected gene expression matrix obtained after removing the effects of the hidden variability is given by:
Y.corrected <- fit$Y.corrRun the code above in your browser using DataLab