Fixed specificity calculations based on #89.