public abstract class BallSplitter extends java.lang.Object implements java.io.Serializable, OptionHandler, RevisionHandler
Constructor and Description |
---|
BallSplitter()
default constructor.
|
BallSplitter(int[] instList,
Instances insts,
EuclideanDistance e)
Creates a new instance of BallSplitter.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String[] |
getOptions()
Gets the current settings of the object.
|
java.lang.String |
getRevision()
Returns the revision string.
|
java.util.Enumeration<Option> |
listOptions()
Returns an enumeration describing the available options.
|
void |
setEuclideanDistanceFunction(EuclideanDistance func)
Sets the distance function used to (or to be used to) build the tree.
|
void |
setInstanceList(int[] instList)
Sets the master index array containing indices of the training instances.
|
void |
setInstances(Instances inst)
Sets the training instances on which the tree is (or is to be) built.
|
void |
setOptions(java.lang.String[] options)
Parses a given list of options.
|
abstract void |
splitNode(BallNode node,
int numNodesCreated)
Splits a node into two.
|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
makeCopy
public BallSplitter()
public BallSplitter(int[] instList, Instances insts, EuclideanDistance e)
instList
- The master index array.insts
- The instances on which the tree is (or is to be) built.e
- The Euclidean distance function to use for splitting.public java.util.Enumeration<Option> listOptions()
listOptions
in interface OptionHandler
public void setOptions(java.lang.String[] options) throws java.lang.Exception
setOptions
in interface OptionHandler
options
- the list of options as an array of stringsjava.lang.Exception
- if an option is not supportedpublic java.lang.String[] getOptions()
getOptions
in interface OptionHandler
public abstract void splitNode(BallNode node, int numNodesCreated) throws java.lang.Exception
node
- The node to split.numNodesCreated
- The number of nodes that so far have been created
for the tree, so that the newly created nodes are assigned
correct/meaningful node numbers/ids.java.lang.Exception
- If there is some problem in splitting the given node.public void setInstances(Instances inst)
inst
- The training instances.public void setInstanceList(int[] instList)
instList
- The master index array.public void setEuclideanDistanceFunction(EuclideanDistance func)
func
- The distance function.public java.lang.String getRevision()
getRevision
in interface RevisionHandler