To categorize a new sample formula_75 external to the training set formula_76, the previous distance metric finds the transition probabilities between formula_75 and all samples in formula_78, formula_79 with formula_80 a normalization.