public class KMeans extends Object
Modifier and Type | Method and Description |
---|---|
static List<RealArray> |
cluster(int nClusters,
RealArray points)
Groups a set of points into the given number of clusters.
|
static RealArray |
distances(RealArray aPts,
RealArray bPts)
Computes point-to-point distances.
|
protected static RealArray |
subsetFurthestFirst(int nCenters,
RealArray points)
Performs subset furthest first initialization.
|
public static final RealArray distances(RealArray aPts, RealArray bPts)
aPts
- the origin points.bPts
- the destination points.RealArray
of distances.public static final List<RealArray> cluster(int nClusters, RealArray points)
nClusters
- the number of clusters.points
- the input.List
of clusters.