org.encog.ml.data
Interface MLData
-
- All Superinterfaces:
- CentroidFactory<MLData>, java.lang.Cloneable
- All Known Subinterfaces:
- MLComplexData, NeuralData
- All Known Implementing Classes:
- BasicMLComplexData, BasicMLData, BasicNeuralData, BiPolarNeuralData, ImageMLData, SparseMLData
public interface MLData extends java.lang.Cloneable, CentroidFactory<MLData>
Defines an array of data. This is an array of double values that could be used either for input data, actual output data or ideal output data.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description voidadd(int index, double value)Add a value to the specified index.voidclear()Clear any data to zero.MLDataclone()Clone this object.double[]getData()doublegetData(int index)Get the element specified index value.voidsetData(double[] data)Set all of the data as an array of doubles.voidsetData(int index, double d)Set the specified element.intsize()-
Methods inherited from interface org.encog.util.kmeans.CentroidFactory
createCentroid
-
-
-
-
Method Detail
-
add
void add(int index, double value)Add a value to the specified index.- Parameters:
index- The index to add to.value- The value to add.
-
clear
void clear()
Clear any data to zero.
-
clone
MLData clone()
Clone this object.- Returns:
- A cloned version of this object.
-
getData
double[] getData()
- Returns:
- All of the elements as an array.
-
getData
double getData(int index)
Get the element specified index value.- Parameters:
index- The index to read.- Returns:
- The value at the specified inedx.
-
setData
void setData(double[] data)
Set all of the data as an array of doubles.- Parameters:
data- An array of doubles.
-
setData
void setData(int index, double d)Set the specified element.- Parameters:
index- The index to set.d- The data for the specified element.
-
size
int size()
- Returns:
- How many elements are stored in this object.
-
-
DMelt 3.0 © DataMelt by jWork.ORG