Package elki.clustering.hierarchical
Class MiniMaxAnderberg.Instance
- java.lang.Object
-
- elki.clustering.hierarchical.AGNES.Instance
-
- elki.clustering.hierarchical.MiniMax.Instance
-
- elki.clustering.hierarchical.MiniMaxAnderberg.Instance
-
- Enclosing class:
- MiniMaxAnderberg<O>
public static class MiniMaxAnderberg.Instance extends MiniMax.Instance
Main worker instance of MiniMax.- Author:
- Erich Schubert
-
-
Field Summary
Fields Modifier and Type Field Description protected double[]
bestd
Cache: best distanceprotected int[]
besti
Cache: index of best distance-
Fields inherited from class elki.clustering.hierarchical.MiniMax.Instance
clusters, dq, ix, iy, protiter
-
Fields inherited from class elki.clustering.hierarchical.AGNES.Instance
builder, end, linkage, mat
-
-
Constructor Summary
Constructors Constructor Description Instance()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected int
findMerge()
Perform the next merge step in AGNES.protected void
merge(int x, int y)
Merges two clusters given by x, y, their points with smallest IDs, and y to keepClusterPrototypeMergeHistory
run(ArrayDBIDs ids, ClusterDistanceMatrix mat, ClusterMergeHistoryBuilder builder, DistanceQuery<?> dq, DBIDArrayMIter prots)
private void
updateMatrices(int x, int y)
Update the entries of the matrices that contain a distance to y, the newly merged cluster.-
Methods inherited from class elki.clustering.hierarchical.MiniMax.Instance
run, updateEntry, updateMatrices
-
Methods inherited from class elki.clustering.hierarchical.AGNES.Instance
merge, shrinkActiveSet, updateMatrix
-
-
-
-
Method Detail
-
run
public ClusterPrototypeMergeHistory run(ArrayDBIDs ids, ClusterDistanceMatrix mat, ClusterMergeHistoryBuilder builder, DistanceQuery<?> dq, DBIDArrayMIter prots)
- Overrides:
run
in classMiniMax.Instance
-
findMerge
protected int findMerge()
Description copied from class:AGNES.Instance
Perform the next merge step in AGNES.- Overrides:
findMerge
in classMiniMax.Instance
- Returns:
- the index that has disappeared, for shrinking the working set
-
merge
protected void merge(int x, int y)
Description copied from class:MiniMax.Instance
Merges two clusters given by x, y, their points with smallest IDs, and y to keep- Overrides:
merge
in classMiniMax.Instance
- Parameters:
x
- first cluster to mergey
- second cluster to merge
-
updateMatrices
private void updateMatrices(int x, int y)
Update the entries of the matrices that contain a distance to y, the newly merged cluster.- Parameters:
x
- first cluster to merge, withx > y
y
- second cluster to merge, withy < x
-
-