idl.tmt.training
Class RandomSelector

java.lang.Object
  |
  +--idl.tmt.training.RandomSelector
All Implemented Interfaces:
TrainingSetConstructor

public class RandomSelector
extends java.lang.Object
implements TrainingSetConstructor

Created on Jun 4, 2004

Author:
jelsas

Field Summary
private  boolean hasBeenRun
           
private  int instanceCount
           
private  int seed
           
 
Fields inherited from interface idl.tmt.training.TrainingSetConstructor
STATUS_COMPLETE, STATUS_NONE
 
Constructor Summary
RandomSelector()
           
 
Method Summary
 Instances constructTrainingSet(IndexedCollection collection)
          Constructs a training set of Instances from the given collection by randomly selecting the specified number of instances from the collection.
 int getInstanceCount()
           
 int getSeed()
           
 java.lang.String getStatus()
           
 void setInstanceCount(int instanceCount)
           
 void setSeed(int seed)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait
 

Field Detail

instanceCount

private int instanceCount

seed

private int seed

hasBeenRun

private boolean hasBeenRun
Constructor Detail

RandomSelector

public RandomSelector()
Method Detail

constructTrainingSet

public Instances constructTrainingSet(IndexedCollection collection)
Constructs a training set of Instances from the given collection by randomly selecting the specified number of instances from the collection.
Specified by:
constructTrainingSet in interface TrainingSetConstructor
See Also:
TrainingSetConstructor.constructTrainingSet(idl.tmt.representation.IndexedCollection)

setInstanceCount

public void setInstanceCount(int instanceCount)

getInstanceCount

public int getInstanceCount()

setSeed

public void setSeed(int seed)

getSeed

public int getSeed()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getStatus

public java.lang.String getStatus()
Specified by:
getStatus in interface TrainingSetConstructor