Skip to content

Main content

Similarity Vs Distance Affine Crosswalk Tool

Apply an explicit affine similarity-to-dissimilarity convention d = maximumSimilarity - similarity; no metric property is asserted.

Loading tool…

Description

Subtract similarity from maximumSimilarity for distance.

Similarity measures compare items under a defined representation. A single coordinate contribution, shared ranked prefix, or histogram overlap has a specific scale and may require aggregation before it becomes a complete similarity measure.

Subtract similarity from maximumSimilarity for distance.

When to use this tool

Use Similarity Vs Distance Affine Crosswalk when you need one comparison component under the stated representation and normalization.

How to use the tool and how it works

  1. Enter similarity, maximumSimilarity. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read distance. Use the output convention below.

Subtract similarity from maximumSimilarity for distance.1

Input fieldMeaning and unitsAccepted input
similaritySimilarityRequired. Finite number.
maximumSimilarityMaximum SimilarityRequired. Finite number.
Output fieldInterpretationReturned shape
distanceDistanceRequired. Finite number.
json
{
  "input": {
    "similarity": 0.7,
    "maximumSimilarity": 1
  },
  "output": {
    "distance": 0.30000000000000004
  }
}

Limitations and assumptions

  • This is an affine dissimilarity crosswalk only; inputs are unrestricted and the result is not automatically nonnegative or a mathematical metric.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
  • Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.

Alternative or Complementary methods

Apply the complete metric to aligned data and check its assumptions before interpreting overall similarity.

References

  1. Calculation and input contract: similarity/similarity-vs-distance-affine-crosswalk — tool.io

Similar or alternative tools