Hi all,
I'm trying to use the result of a PLSDA model outside R, but I'm having a
really hard time finding documentation on how to write the model from the
results in the fit object.
In order to provide a good starting point I believe that this code creates
a good model that is stored in the fit variable. I know that I can use the
predict function to create the predictions but I would like to "write the
predict function outside R".

Can anyone provide me with the equations? Thanks


# load the package
library(caret)
data(iris)
x <- iris[,1:4]
y <- iris[,5]
# fit model
fit <- plsda(x, y, probMethod="Bayes")
# summarize the fit
summary(fit)
# make predictions
predictions <- predict(fit, iris[,1:4])
# summarize accuracy
table(predictions, iris$Species)

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to