Interface ObjectSimilarityScore<T,R>
- Type Parameters:
T
- Input typeR
- The type of similarity score unit used by this score.
- All Superinterfaces:
BiFunction<T,
T, R>
- All Known Subinterfaces:
EditDistance<R>
,SimilarityScore<R>
- All Known Implementing Classes:
CosineDistance
,HammingDistance
,IntersectionSimilarity
,JaccardDistance
,JaccardSimilarity
,JaroWinklerDistance
,JaroWinklerSimilarity
,LevenshteinDetailedDistance
,LevenshteinDistance
,LongestCommonSubsequence
,LongestCommonSubsequenceDistance
Scores the similarity between two
Object
s of the same type.
A string similarity score is intended to have some of the properties of a metric, yet allowing for exceptions, like the Jaro-Winkler similarity score.
A similarity score is the function d: [X * X] -> [0, INFINITY)
with the following properties:
d(x,y) >= 0
, non-negativity or separation axiomd(x,y) == d(y,x)
, symmetry.
Notice, these are two of the properties that contribute to d
being a metric.
- Since:
- 1.13.0
-
Method Summary
Methods inherited from interface java.util.function.BiFunction
andThen
-
Method Details
-
apply
Compares two Objects.- Specified by:
apply
in interfaceBiFunction<T,
T, R> - Parameters:
left
- the "left" or "first" input.right
- the "right" or "second" input.- Returns:
- The similarity score between two Objects.
-