public class CLARA extends PAM
dm, iterLimit, medoids, rand, repeats, seedSelection, storeMedoids
Constructor and Description |
---|
CLARA() |
CLARA(CLARA toCopy)
Copy constructor
|
CLARA(DistanceMetric dm) |
CLARA(DistanceMetric dm,
Random rand) |
CLARA(DistanceMetric dm,
Random rand,
SeedSelectionMethods.SeedSelection seedSelection) |
CLARA(int sampleCount,
DistanceMetric dm,
Random rand,
SeedSelectionMethods.SeedSelection seedSelection) |
CLARA(int sampleSize,
int sampleCount,
DistanceMetric dm,
Random rand,
SeedSelectionMethods.SeedSelection seedSelection) |
Modifier and Type | Method and Description |
---|---|
CLARA |
clone() |
protected double |
cluster(DataSet data,
boolean doInit,
int[] medioids,
int[] assignments,
List<Double> cacheAccel)
Performs the actual work of PAM.
|
int[] |
cluster(DataSet dataSet,
int clusters,
int[] designations) |
int |
getSampleCount() |
int |
getSampleSize() |
void |
setSampleCount(int sampleCount)
Sets the number of times
PAM will be applied to different samples from the data set. |
void |
setSampleSize(int sampleSize)
Sets the number of samples CLARA should take from the data set to perform
PAM on. |
cluster, cluster, cluster, cluster, cluster, getMaxIterations, getMedoids, getSeedSelection, setMaxIterations, setSeedSelection, setStoreMedoids
cluster, cluster, cluster, cluster
cluster, cluster, createClusterListFromAssignmentArray, getDatapointsFromCluster, supportsWeightedData
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
cluster, cluster, supportsWeightedData
public CLARA(int sampleSize, int sampleCount, DistanceMetric dm, Random rand, SeedSelectionMethods.SeedSelection seedSelection)
public CLARA(int sampleCount, DistanceMetric dm, Random rand, SeedSelectionMethods.SeedSelection seedSelection)
public CLARA(DistanceMetric dm, Random rand, SeedSelectionMethods.SeedSelection seedSelection)
public CLARA(DistanceMetric dm, Random rand)
public CLARA(DistanceMetric dm)
public CLARA()
public CLARA(CLARA toCopy)
toCopy
- the object to copypublic int getSampleCount()
PAM
will be applied to a sample from the data set.public void setSampleCount(int sampleCount)
PAM
will be applied to different samples from the data set.sampleCount
- the number of times to apply sampeling.public int getSampleSize()
PAM
on.public void setSampleSize(int sampleSize)
PAM
on.sampleSize
- the number of samples to takeprotected double cluster(DataSet data, boolean doInit, int[] medioids, int[] assignments, List<Double> cacheAccel)
PAM
cluster
in class PAM
data
- the data set to apply PAM todoInit
- true
if the initialization procedure of training the distance metric, initiating its cache, and selecting he seeds, should be done.medioids
- the array to store the indices that get chosen as the medoids. The length of the array indicates how many medoids should be obtained.assignments
- an array of the same length as data, each value indicating what cluster that point belongs to.cacheAccel
- the pre-computed distance acceleration cache. May be null
.public int[] cluster(DataSet dataSet, int clusters, int[] designations)
cluster
in interface KClusterer
cluster
in class PAM
Copyright © 2017. All rights reserved.