org.knime.base.node.mine.cluster.hierarchical.distfunctions
Class EuclideanDist
java.lang.Object
org.knime.base.node.mine.cluster.hierarchical.distfunctions.MinkowskiDist
org.knime.base.node.mine.cluster.hierarchical.distfunctions.EuclideanDist
- All Implemented Interfaces:
- Serializable, DistanceFunction
public class EuclideanDist
- extends MinkowskiDist
Calculates the distance for two data rows based on the euclidean distance.
- Author:
- Christoph Sieb, University of Konstanz
- See Also:
- Serialized Form
Constructor Summary |
protected |
EuclideanDist()
Creates a Euclidean distance object from an Minkowski distance
which means the power is two. |
Method Summary |
double |
calcDistance(DataRow firstDataRow,
DataRow secondDataRow,
int[] includedCols)
Calculates the distance between two data rows based on the
Euclidean distance. |
String |
toString()
Returns the String representation of this distance function. |
EUCLIDEAN_DISTANCE
public static final EuclideanDist EUCLIDEAN_DISTANCE
- An instance of this distance function.
EuclideanDist
protected EuclideanDist()
- Creates a Euclidean distance object from an Minkowski distance
which means the power is two.
calcDistance
public double calcDistance(DataRow firstDataRow,
DataRow secondDataRow,
int[] includedCols)
- Calculates the distance between two data rows based on the
Euclidean distance.
- Specified by:
calcDistance
in interface DistanceFunction
- Overrides:
calcDistance
in class MinkowskiDist
- Parameters:
firstDataRow
- the first data row used to calculate the distancesecondDataRow
- the second data row used to calculate the distanceincludedCols
- the columns to include into the distance calculation
- Returns:
- the distance of the two rows
toString
public String toString()
- Returns the String representation of this distance function.
- Overrides:
toString
in class MinkowskiDist
- Returns:
- the String representation
Copyright, 2003 - 2010. All rights reserved.
University of Konstanz, Germany.
Chair for Bioinformatics and Information Mining, Prof. Dr. Michael R. Berthold.
You may not modify, publish, transmit, transfer or sell, reproduce, create derivative works from, distribute, perform, display,
or in any way exploit any of the content, in whole or in part, except as otherwise expressly permitted in writing by the
copyright owner or as specified in the license file distributed with this product.