# NOT RUN {
set.seed(120)
x <- matrix(rnorm(1000*20), ncol=20)
y <- sample(c(1:4), size=20, replace=TRUE)
alldf <- cbind.data.frame(t(x), y)
# assure it is a factor (otherwise error message)
alldf$y <- factor(alldf$y)
library(MLInterfaces)
(mlobj <- MLearn(y ~ .,
data = alldf,
.method = pamrI,
trainInd = 1:15))
# }
Run the code above in your browser using DataLab