jminhep.cluster
Class Get
- java.lang.Object
-
- jminhep.cluster.Get
-
public class Get extends java.lang.ObjectSome useful methods related to the clustering procedure
-
-
Constructor Summary
Constructors Constructor and Description Get()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static doublecalcDistance(double[] a1, double[] a2)This method calculates the Euclidean distance between two N-ncolsional vectors.static doublecalcSquaredDistance(double[] a1, double[] a2)This method calculates the squared distance between two N-dimesional vectors.static doublecompactness(double[][] indat, int[] assignment, int numClusters, double[][] clusterCenters)This method returns the cluster compactness
-
-
-
Method Detail
-
compactness
public static double compactness(double[][] indat, int[] assignment, int numClusters, double[][] clusterCenters)This method returns the cluster compactness- Parameters:
indat[][]- data matrixnumClusters- number of clustersclusterCenters[][]- cluster centers- Returns:
- compactness
-
calcSquaredDistance
public static double calcSquaredDistance(double[] a1, double[] a2)This method calculates the squared distance between two N-dimesional vectors.- Parameters:
a1- the first data vector.a2- the second data vector.- Returns:
- the squared distance between those vectors.
-
calcDistance
public static double calcDistance(double[] a1, double[] a2)This method calculates the Euclidean distance between two N-ncolsional vectors.- Parameters:
a1- the first data vector.a2- the second data vector.- Returns:
- the Euclidean distance between those vectors.
-
-
DMelt 3.0 © DataMelt by jWork.ORG