jsat.clustering.evaluation
Class DaviesBouldinIndex
- java.lang.Object
-
- jsat.clustering.evaluation.DaviesBouldinIndex
-
- All Implemented Interfaces:
- ClusterEvaluation
public class DaviesBouldinIndex extends java.lang.Object implements ClusterEvaluation
A measure for evaluating the quality of a clustering by measuring the distances of points to their centroids.
-
-
Constructor Summary
Constructors Constructor and Description DaviesBouldinIndex()Creates a new DaviesBouldinIndex using theEuclideanDistance.DaviesBouldinIndex(DaviesBouldinIndex toCopy)Copy constructorDaviesBouldinIndex(DistanceMetric dm)Creates a new DaviesBouldinIndex
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description DaviesBouldinIndexclone()doubleevaluate(int[] designations, DataSet dataSet)Evaluates the clustering of the given clustering.doubleevaluate(java.util.List<java.util.List<DataPoint>> dataSets)Evaluates the clustering of the given set of clusters.
-
-
-
Constructor Detail
-
DaviesBouldinIndex
public DaviesBouldinIndex()
Creates a new DaviesBouldinIndex using theEuclideanDistance.
-
DaviesBouldinIndex
public DaviesBouldinIndex(DaviesBouldinIndex toCopy)
Copy constructor- Parameters:
toCopy- the object to copy
-
DaviesBouldinIndex
public DaviesBouldinIndex(DistanceMetric dm)
Creates a new DaviesBouldinIndex- Parameters:
dm- the distance measure to use when computing
-
-
Method Detail
-
evaluate
public double evaluate(int[] designations, DataSet dataSet)Description copied from interface:ClusterEvaluationEvaluates the clustering of the given clustering.- Specified by:
evaluatein interfaceClusterEvaluation- Parameters:
designations- the array that stores the cluster assignments for each data point in the data setdataSet- the data set that contains all data points- Returns:
- a value in [0, Inf) that indicates the quality of the clustering.
-
evaluate
public double evaluate(java.util.List<java.util.List<DataPoint>> dataSets)
Description copied from interface:ClusterEvaluationEvaluates the clustering of the given set of clusters.- Specified by:
evaluatein interfaceClusterEvaluation- Parameters:
dataSets- a list of lists, where the size of the first index indicates the the number of clusters, and the list at each index is the data points that make up each cluster.- Returns:
- a value in [0, Inf) that indicates the quality of the clustering.
-
clone
public DaviesBouldinIndex clone()
- Specified by:
clonein interfaceClusterEvaluation- Overrides:
clonein classjava.lang.Object
-
-
DataMelt 3.0 © DataMelt by jWork.ORG