|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectweka.classifiers.trees.RandomRegressionForest.Node
public class RandomRegressionForest.Node
TODO: description of class
| Field Summary | |
|---|---|
protected RandomRegressionForest.Node |
m_Less
|
protected weka.classifiers.functions.LinearRegression |
m_LinearReg
|
protected RandomRegressionForest.Node |
m_More
|
protected int |
m_SplitIndex
|
protected double |
m_SplitValue
|
| Constructor Summary | |
|---|---|
RandomRegressionForest.Node(weka.core.Instances data,
Random r,
int min)
the constructor |
|
| Method Summary | |
|---|---|
double |
classifyInstance(weka.core.Instance instance)
classifies the given instance |
void |
findRandomSplit(weka.core.Instances data,
Random r,
int min)
determines a random split for the data, tries 10 pairs. |
void |
prefix(int indent,
StringBuffer sb)
generates the tree structure prefix |
boolean |
subsetSizesOK(weka.core.Instances data,
int min)
tests whether the leaf threshold is OK |
void |
toString(int indent,
StringBuffer sb,
List<String> models)
Generates a string representation of the node. |
void |
turnIntoLeaf(weka.core.Instances data)
turns the node into a leaf |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected double m_SplitValue
protected int m_SplitIndex
protected weka.classifiers.functions.LinearRegression m_LinearReg
protected RandomRegressionForest.Node m_Less
protected RandomRegressionForest.Node m_More
| Constructor Detail |
|---|
public RandomRegressionForest.Node(weka.core.Instances data,
Random r,
int min)
throws Exception
data - the data to user - the random number generator to usemin - the leaf threshold
Exception - if something goes wrong| Method Detail |
|---|
public void turnIntoLeaf(weka.core.Instances data)
throws Exception
data - the data to use for linear regression
Exception - if training of LinearRegression fails
public double classifyInstance(weka.core.Instance instance)
throws Exception
instance - the instance to classify
Exception - if the classification fails
public void findRandomSplit(weka.core.Instances data,
Random r,
int min)
data - the data to user - the random number generator formin - the leaf thresholdm_SplitIndex,
m_SplitValue
public boolean subsetSizesOK(weka.core.Instances data,
int min)
data - the data to usemin - the leaf threshold
public void prefix(int indent,
StringBuffer sb)
indent - the depthsb - the StringBuffer to add the prefix to
public void toString(int indent,
StringBuffer sb,
List<String> models)
indent - the depthsb - the StringBuffer to add the output tomodels - the list to add the generated output to
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||