com.meapsoft
Class CosineDist
java.lang.Object
com.meapsoft.ChunkDist
com.meapsoft.CosineDist
- All Implemented Interfaces:
- java.util.Comparator, java.io.Serializable
- public class CosineDist
- extends ChunkDist
Simple distance metric that calculates 1 - the cosine of the angle
between two chunks' feature vectors.
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CosineDist
public CosineDist()
CosineDist
public CosineDist(ChunkDist o)
CosineDist
public CosineDist(int[] i)
CosineDist
public CosineDist(ChunkDist o,
int[] i)
distance
public double distance(Chunk ch1,
Chunk ch2)
- Description copied from class:
ChunkDist
- Compute distance between two Chunks
- Overrides:
distance
in class ChunkDist