4
$\begingroup$

While I was going through the question How to interpret classification report of scikit-learn? with the following metrics -

enter image description here

I saw following claim (in the accepted answer) -

you cannot compare the precision and the recall over two classes. This only means you're classifier is better to find class 0 over class 1.

I am not able to understand this statement. Shouldn't, in theory atleast, we be striving to get as high score as possible for both the classes separately? Also, this example is for a balanced class problem. What about imbalanced classes? I am assuming that we have a single binary classifier that is estimating P(Y=1|X) only. Could you please help? Thanks

$\endgroup$

1 Answer 1

2
+50
$\begingroup$

The cited comment makes no sense and is contradictory on its face: if you cannot compare them, then there is no "it only means". I notice that a user has sought clarification from the person who posted the answer, but no clarification has been forthcoming. Interpreting charitably, I suspect that the answerer is alluding to the fact that a binary classification algorithm might overestimate the frequency of one class, making its precision in correctly identifying that class higher than the precision in correctly identifying the other class. This doesn't really mean that you can't compare the two precisions --- it just means that caution is needed in interpreting what a disparity in precision means. In any case, just ignore the comment in that answer; at best it is a poorly worded allusion to an unexplained principle.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.