caretStack | R Documentation |
Find a good linear combination of several classification or regression models, using either linear regression, elastic net regression, or greedy optimization.
caretStack(all.models, ...)
all.models |
a list of caret models to ensemble. |
... |
additional arguments to pass to the optimization function |
Check the models, and make a matrix of obs and preds
S3 caretStack object
https://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.60.2859&rep=rep1&type=pdf
## Not run:
library("rpart")
models <- caretList(
x=iris[1:50,1:2],
y=iris[1:50,3],
trControl=trainControl(method="cv"),
methodList=c("rpart", "glm")
)
caretStack(models, method="glm")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.