edu.cmu.minorthird.classify.algorithms.trees
Class RandomForests
java.lang.Object
edu.cmu.minorthird.classify.BatchClassifierLearner
edu.cmu.minorthird.classify.BatchBinaryClassifierLearner
edu.cmu.minorthird.classify.algorithms.trees.RandomForests
- All Implemented Interfaces:
- BinaryClassifierLearner, ClassifierLearner, java.lang.Cloneable
public class RandomForests
- extends BatchBinaryClassifierLearner
Random Forests implementation. See http://www.stat.berkeley.edu/~breiman/RandomForests/
For algorith details.
- Author:
- Alexander Friedman
Nested Class Summary |
static class |
RandomForests.VotingClassifier
A set of RandomTree Classifiers
FIXME!! All of this stuff is copied directly for AdaBoost with (very)
minor modifications |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RandomForests
public RandomForests()
RandomForests
public RandomForests(int numComponents)
RandomForests
public RandomForests(FastRandomTreeLearner baseLearner,
int numComponents)
setThreaded
public RandomForests setThreaded(boolean b)
setThreadCount
public RandomForests setThreadCount(int c)
setCollectStats
public RandomForests setCollectStats(boolean b)
setScaleWeights
public RandomForests setScaleWeights(boolean b)
setSelectionSizeLog
public RandomForests setSelectionSizeLog()
setSelectionSize
public RandomForests setSelectionSize(int c)
RepeatableForest
public static RandomForests RepeatableForest()
batchTrain
public Classifier batchTrain(Dataset dataset)
- Description copied from class:
BatchClassifierLearner
- subclasses should use this method to implement a batch supervised learning algorithm.
- Specified by:
batchTrain
in class BatchClassifierLearner
getDatasetFeatures
public static java.util.Vector<Feature> getDatasetFeatures(Dataset dataset)
- Return a vector of all features in the dataset.
This should really be in the 'Dataset' interface
- Parameters:
dataset
-
- Returns:
- a vector of all features in the dataset