Class EuclideanIntegerPoint
- java.lang.Object
-
- org.apache.commons.math3.stat.clustering.EuclideanIntegerPoint
-
- All Implemented Interfaces:
java.io.Serializable
,Clusterable<EuclideanIntegerPoint>
@Deprecated public class EuclideanIntegerPoint extends java.lang.Object implements Clusterable<EuclideanIntegerPoint>, java.io.Serializable
Deprecated.As of 3.2 (to be removed in 4.0), useDoublePoint
insteadA simple implementation ofClusterable
for points with integer coordinates.- Since:
- 2.0
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private int[]
point
Deprecated.Point coordinates.private static long
serialVersionUID
Deprecated.Serializable version identifier.
-
Constructor Summary
Constructors Constructor Description EuclideanIntegerPoint(int[] point)
Deprecated.Build an instance wrapping an integer array.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description EuclideanIntegerPoint
centroidOf(java.util.Collection<EuclideanIntegerPoint> points)
Deprecated.Returns the centroid of the given Collection of points.double
distanceFrom(EuclideanIntegerPoint p)
Deprecated.Returns the distance from the given point.boolean
equals(java.lang.Object other)
Deprecated.int[]
getPoint()
Deprecated.Get the n-dimensional point in integer space.int
hashCode()
Deprecated.java.lang.String
toString()
Deprecated.
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
Deprecated.Serializable version identifier.- See Also:
- Constant Field Values
-
point
private final int[] point
Deprecated.Point coordinates.
-
-
Method Detail
-
getPoint
public int[] getPoint()
Deprecated.Get the n-dimensional point in integer space.- Returns:
- a reference (not a copy!) to the wrapped array
-
distanceFrom
public double distanceFrom(EuclideanIntegerPoint p)
Deprecated.Returns the distance from the given point.- Specified by:
distanceFrom
in interfaceClusterable<EuclideanIntegerPoint>
- Parameters:
p
- the point to compute the distance from- Returns:
- the distance from the given point
-
centroidOf
public EuclideanIntegerPoint centroidOf(java.util.Collection<EuclideanIntegerPoint> points)
Deprecated.Returns the centroid of the given Collection of points.- Specified by:
centroidOf
in interfaceClusterable<EuclideanIntegerPoint>
- Parameters:
points
- the Collection of points to compute the centroid of- Returns:
- the centroid of the given Collection of Points
-
equals
public boolean equals(java.lang.Object other)
Deprecated.- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
Deprecated.- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
Deprecated.- Overrides:
toString
in classjava.lang.Object
- Since:
- 2.1
-
-