Title: | Fit and Deploy Rotation Forest Models |
---|---|
Description: | Fit and deploy rotation forest models ("Rodriguez, J.J., Kuncheva, L.I., 2006. Rotation forest: A new classifier ensemble method. IEEE Trans. Pattern Anal. Mach. Intell. 28, 1619-1630 <doi:10.1109/TPAMI.2006.211>") for binary classification. Rotation forest is an ensemble method where each base classifier (tree) is fit on the principal components of the variables of random partitions of the feature set. |
Authors: | Michel Ballings and Dirk Van den Poel |
Maintainer: | Michel Ballings <[email protected]> |
License: | GPL (>= 2) |
Version: | 0.1.3 |
Built: | 2025-02-09 02:58:23 UTC |
Source: | https://github.com/cran/rotationForest |
Prediction of new data using rotationForest.
## S3 method for class 'rotationForest' predict(object, newdata, all = FALSE, ...)
## S3 method for class 'rotationForest' predict(object, newdata, all = FALSE, ...)
object |
An object of class |
newdata |
A data frame with the same predictors as in the training data. |
all |
Return the predictions per tree instead of the average. |
... |
Not used currently. |
A vector containing the response scores.
Michel Ballings and Dirk Van den Poel, Maintainer: [email protected]
Rodriguez, J.J., Kuncheva, L.I., 2006. Rotation forest: A new classifier ensemble method. IEEE Trans. Pattern Anal. Mach. Intell. 28, 1619-1630. doi:10.1109/TPAMI.2006.211
data(iris) y <- as.factor(ifelse(iris$Species[1:100]=="setosa",0,1)) x <- iris[1:100,-5] rF <- rotationForest(x,y) predict(object=rF,newdata=x)
data(iris) y <- as.factor(ifelse(iris$Species[1:100]=="setosa",0,1)) x <- iris[1:100,-5] rF <- rotationForest(x,y) predict(object=rF,newdata=x)
rotationForest
implements an ensemble method where each base classifier (tree) is fit on the principal components of the variables of random partitions of the feature set.
rotationForest(x, y, K = round(ncol(x)/3, 0), L = 10, verbose = FALSE, ...)
rotationForest(x, y, K = round(ncol(x)/3, 0), L = 10, verbose = FALSE, ...)
x |
A data frame of predictors (numeric, or integer). Categorical variables need to be transformed to indicator (dummy) variables. At minimum |
y |
A factor containing the response vector. Only {0,1} is allowed. |
K |
The number of variable subsets. The default is the value |
L |
The number of base classifiers (trees using the |
verbose |
Boolean. Should information about the subsets be printed? |
... |
Arguments to |
An object of class rotationForest
, which is a list with the following elements:
models |
A list of trees. |
loadings |
A list of loadings. |
columnnames |
Column names of x. |
Michel Ballings and Dirk Van den Poel, Maintainer: [email protected]
Rodriguez, J.J., Kuncheva, L.I., 2006. Rotation forest: A new classifier ensemble method. IEEE Trans. Pattern Anal. Mach. Intell. 28, 1619-1630. doi:10.1109/TPAMI.2006.211
data(iris) y <- as.factor(ifelse(iris$Species[1:100]=="setosa",0,1)) x <- iris[1:100,-5] rF <- rotationForest(x,y) predict(object=rF,newdata=x)
data(iris) y <- as.factor(ifelse(iris$Species[1:100]=="setosa",0,1)) x <- iris[1:100,-5] rF <- rotationForest(x,y) predict(object=rF,newdata=x)
rotationForestNews
shows the NEWS file of the rotationForest package.
rotationForestNews()
rotationForestNews()
Michel Ballings and Dirk Van den Poel, Maintainer: [email protected]
rotationForestNews()
rotationForestNews()