|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.encog.ml.kmeans.BasicCluster
public class BasicCluster
Holds a cluster of MLData items that have been clustered by the KMeansClustering class.
Constructor Summary | |
---|---|
BasicCluster(Cluster<BasicMLDataPair> cluster)
Construct a cluster from another. |
Method Summary | |
---|---|
void |
add(MLData pair)
Add to the cluster. |
MLDataSet |
createDataSet()
Create a dataset from the clustered data. |
MLData |
get(int pos)
Get the specified data item by index. |
Centroid<?> |
getCentroid()
|
List<MLData> |
getData()
|
void |
remove(MLData pair)
Remove the specified item. |
void |
setCentroid(BasicMLDataPairCentroid c)
Set the centroid. |
int |
size()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BasicCluster(Cluster<BasicMLDataPair> cluster)
cluster
- The other cluster.Method Detail |
---|
public final void add(MLData pair)
add
in interface MLCluster
pair
- The pair to add.public final MLDataSet createDataSet()
createDataSet
in interface MLCluster
public final MLData get(int pos)
get
in interface MLCluster
pos
- The index of the data item to get.
public final Centroid<?> getCentroid()
public final List<MLData> getData()
getData
in interface MLCluster
public final void remove(MLData pair)
remove
in interface MLCluster
pair
- The item to remove.public final void setCentroid(BasicMLDataPairCentroid c)
c
- The new centroid.public final int size()
size
in interface MLCluster
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |