|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.encog.ml.data.basic.BasicMLData
public class BasicMLData
Basic implementation of the MLData interface that stores the data in an array.
| Constructor Summary | |
|---|---|
BasicMLData(double[] d)
Construct this object with the specified data. |
|
BasicMLData(int size)
Construct this object with blank data and a specified size. |
|
BasicMLData(MLData d)
Construct a new BasicMLData object from an existing one. |
|
| Method Summary | |
|---|---|
void |
add(int index,
double value)
Add a value to the specified index. |
void |
clear()
Clear any data to zero. |
MLData |
clone()
Clone this object. |
double[] |
getData()
|
double |
getData(int index)
Get the element specified index value. |
void |
setData(double[] theData)
Set all of the data as an array of doubles. |
void |
setData(int index,
double d)
Set the specified element. |
int |
size()
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public BasicMLData(double[] d)
d - The data to construct this object with.public BasicMLData(int size)
size - The amount of data to store.public BasicMLData(MLData d)
d - The object to be copied.| Method Detail |
|---|
public final void add(int index,
double value)
add in interface MLDataindex - The index to add to.value - The value to add.public final void clear()
clear in interface MLDatapublic final MLData clone()
clone in interface MLDataclone in class Objectpublic final double[] getData()
getData in interface MLDatapublic final double getData(int index)
getData in interface MLDataindex - The index to read.
public final void setData(double[] theData)
setData in interface MLDatatheData - An array of doubles.
public final void setData(int index,
double d)
setData in interface MLDataindex - The index to set.d - The data for the specified element.public final int size()
size in interface MLDatapublic final String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||