|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.neuroph.core.learning.TrainingSet
public class TrainingSet
A set of training elements for training neural network.
Constructor Summary | |
---|---|
TrainingSet()
Creates an instance of new empty TrainingSet |
|
TrainingSet(java.lang.String label)
Creates an instance of new empty TrainingSet with given label |
Method Summary | |
---|---|
void |
addElement(TrainingElement el)
Adds new training element to this training set |
void |
clear()
Removes all alements from training set |
TrainingElement |
elementAt(int idx)
Returns training element at specified index position |
java.util.Enumeration<TrainingElement> |
elements()
Returns Enumeration for iterating training elements collection |
java.lang.String |
getFilePath()
Returns full file path for this training set |
java.lang.String |
getLabel()
Returns label for this training set |
boolean |
isEmpty()
Returns true if training set is empty, false otherwise |
java.util.Iterator<TrainingElement> |
iterator()
Returns Iterator for iterating training elements collection |
static TrainingSet |
load(java.lang.String filePath)
Loads training set from the specified file |
void |
removeElementAt(int idx)
Removes training element at specified index position |
void |
save()
Saves this training set to file specified in its filePath field |
void |
save(java.lang.String filePath)
Saves this training set to the specified file |
void |
setFilePath(java.lang.String filePath)
Sets full file path for this training set |
void |
setLabel(java.lang.String label)
Sets label for this training set |
int |
size()
Returns number of training elements in this training set set |
java.lang.String |
toString()
Returns label of this training set |
java.util.Vector<TrainingElement> |
trainingElements()
Returns training elements collection |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public TrainingSet()
public TrainingSet(java.lang.String label)
label
- training set labelMethod Detail |
---|
public void addElement(TrainingElement el)
el
- training element to addpublic void removeElementAt(int idx)
idx
- position of element to removepublic java.util.Enumeration<TrainingElement> elements()
public java.util.Iterator<TrainingElement> iterator()
public java.util.Vector<TrainingElement> trainingElements()
public TrainingElement elementAt(int idx)
idx
- index position of training element to return
public void clear()
public boolean isEmpty()
public int size()
public java.lang.String getLabel()
public void setLabel(java.lang.String label)
label
- label for this training setpublic void setFilePath(java.lang.String filePath)
filePath
- public java.lang.String getFilePath()
public java.lang.String toString()
toString
in class java.lang.Object
public void save(java.lang.String filePath)
filePath
- public void save()
public static TrainingSet load(java.lang.String filePath)
filePath
- training set file
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |