Skip to main content

dice_coefficient

Function dice_coefficient 

Source
pub fn dice_coefficient(a: &str, b: &str) -> f64
Expand description

Compute the Dice coefficient (bigram overlap) between two strings.

The Dice coefficient is 2 * |intersection of bigrams| / (|bigrams_a| + |bigrams_b|).