public class DeterministicAnnealing extends CentroidClustering<double[],double[]>
centroids, distance, distortionk, OUTLIER, size, y| Constructor and Description |
|---|
DeterministicAnnealing(double distortion,
double[][] centroids,
int[] y)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
static DeterministicAnnealing |
fit(double[][] data,
int Kmax)
Clustering data into k clusters.
|
static DeterministicAnnealing |
fit(double[][] data,
int Kmax,
double alpha,
int maxIter,
double tol,
double splitTol)
Clustering data into k clusters.
|
compareTo, predict, toStringrun, seedpublic DeterministicAnnealing(double distortion,
double[][] centroids,
int[] y)
distortion - the total distortion.centroids - the centroids of each cluster.y - the cluster labels.public static DeterministicAnnealing fit(double[][] data, int Kmax)
data - the input data of which each row is an observation.Kmax - the maximum number of clusters.public static DeterministicAnnealing fit(double[][] data, int Kmax, double alpha, int maxIter, double tol, double splitTol)
data - the input data of which each row is an observation.Kmax - the maximum number of clusters.alpha - the temperature T is decreasing as T = T * alpha.
alpha has to be in (0, 1).maxIter - the maximum number of iterations at each temperature.tol - the tolerance of convergence test.splitTol - the tolerance to split a cluster.