79105520

Date: 2024-10-19 17:27:36
Score: 0.5
Natty:
Report link

If one considers muti-class classification then your formulas for micro-averaged precision and recall are incorrect, in particular their denominators. Also, if ttl_samples denotes the total number of samples then it is also incorrect - in the presented case it is equal 125 (assuming TN = 0).

In the multi-class case the "positive" and the "negative" are treated as two classes and micro-averaged precision (and recall) is calculated as (TP+TN)/(TP+TN+FP+FN), i.e. expresses how many samples among all the classified samples are classified to the proper class, which is equal to the accuracy. In such a case TP and TN should be interpreted as the number of samples correctly classified to, respectively, the first and the second class. TN in your case is apparently equal 0.

Your formula for "micro-averaged precision" is valid for binary classification case when we effectively consider only the positive class.

Reasons:
  • Whitelisted phrase (-1): in your case
  • Long answer (-0.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: kewals