Class DistanceBasedInitializationWithMedian<O>
- java.lang.Object
-
- elki.clustering.affinitypropagation.DistanceBasedInitializationWithMedian<O>
-
- Type Parameters:
O
- Object type
- All Implemented Interfaces:
AffinityPropagationInitialization<O>
public class DistanceBasedInitializationWithMedian<O> extends java.lang.Object implements AffinityPropagationInitialization<O>
Distance based initialization.- Since:
- 0.6.0
- Author:
- Erich Schubert
-
-
Field Summary
Fields Modifier and Type Field Description (package private) Distance<? super O>
distance
Distance function.(package private) double
quantile
Quantile to use.-
Fields inherited from interface elki.clustering.affinitypropagation.AffinityPropagationInitialization
QUANTILE_ID
-
-
Constructor Summary
Constructors Constructor Description DistanceBasedInitializationWithMedian(Distance<? super O> distance, double quantile)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TypeInformation
getInputTypeRestriction()
Get the data type information for the similarity computations.double[][]
getSimilarityMatrix(Relation<O> relation, ArrayDBIDs ids)
Compute the initial similarity matrix.
-
-
-
Method Detail
-
getSimilarityMatrix
public double[][] getSimilarityMatrix(Relation<O> relation, ArrayDBIDs ids)
Description copied from interface:AffinityPropagationInitialization
Compute the initial similarity matrix.- Specified by:
getSimilarityMatrix
in interfaceAffinityPropagationInitialization<O>
- Parameters:
relation
- Data relationids
- indexed DBIDs- Returns:
- Similarity matrix
-
getInputTypeRestriction
public TypeInformation getInputTypeRestriction()
Description copied from interface:AffinityPropagationInitialization
Get the data type information for the similarity computations.- Specified by:
getInputTypeRestriction
in interfaceAffinityPropagationInitialization<O>
- Returns:
- Data type
-
-