Previous topic

medpy.metric.binary.sensitivity

Next topic

medpy.metric.binary.true_positive_rate

This Page

medpy.metric.binary.specificity

medpy.metric.binary.specificity(result, reference)[source]

Specificity.

Parameters:

result : array_like

Input data containing objects. Can be any type but will be converted into binary: background where 0, object everywhere else.

reference : array_like

Input data containing objects. Can be any type but will be converted into binary: background where 0, object everywhere else.

Returns:

specificity : float

The specificity between two binary datasets, here mostly binary objects in images, which denotes the fraction of correctly returned negatives. The specificity is not symmetric.

See also

sensitivity

Notes

Not symmetric. The completment of the specificity is sensitivity. High recall means that an algorithm returned most of the irrelevant results.

References

[R17]https://en.wikipedia.org/wiki/Sensitivity_and_specificity
[R18]http://en.wikipedia.org/wiki/Confusion_matrix#Table_of_confusion