|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.knime.base.node.mine.decisiontree2.learner.Split
public abstract class Split
Calculates the best split for a given attribute list and the original class distribution.
Field Summary | |
---|---|
protected SplitQualityMeasure |
m_splitQualityMeasure
The quality measure to be used for the best split point calculation. |
Constructor Summary | |
---|---|
Split(InMemoryTable table,
int attributeIndex,
SplitQualityMeasure splitQualityMeasure)
Constructs the best split for the given attribute list and the class distribution. |
Method Summary | |
---|---|
abstract boolean |
canBeFurtherUsed()
Returns true if it makes sense to use this split's attribute further in deeper levels, false if not. |
int |
getAttributeIndex()
Returns the index of the attribute this split object is responsible for. |
double |
getBestQualityMeasure()
Returns the quality index of this split. |
abstract int |
getNumberPartitions()
Return the number of partitions resulting from this split. |
abstract int |
getPartitionForRow(DataRowWeighted row)
Returns the partition the given row belongs to according to this split. |
abstract double[] |
getPartitionWeights()
Returns the partition weights. |
String |
getQualityMeasureName()
|
String |
getSplitAttributeName()
Returns the name of this split's attribute. |
InMemoryTable |
getTable()
Returns the InMemoryTable . |
boolean |
isValidSplit()
Whether this split is a valid split. |
protected void |
setBestQualityMeasure(double bestGini)
To set the quality index once calculated by the detailed implementatioins. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected final SplitQualityMeasure m_splitQualityMeasure
Constructor Detail |
---|
public Split(InMemoryTable table, int attributeIndex, SplitQualityMeasure splitQualityMeasure)
table
- the table for which to create the splitattributeIndex
- the index specifying the attribute for which to
calculate the splitsplitQualityMeasure
- the quality measure to determine the best
split (e.g. gini or gain ratio)Method Detail |
---|
public InMemoryTable getTable()
InMemoryTable
.
InMemoryTable
public double getBestQualityMeasure()
protected void setBestQualityMeasure(double bestGini)
bestGini
- the gini index to setpublic abstract int getNumberPartitions()
public String getSplitAttributeName()
public String getQualityMeasureName()
public int getAttributeIndex()
public boolean isValidSplit()
public abstract boolean canBeFurtherUsed()
public abstract int getPartitionForRow(DataRowWeighted row)
row
- the row for which to get the partition index
public abstract double[] getPartitionWeights()
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |