Orange Forum • View topic - Precision, recall and F1 measures for the entire system

Precision, recall and F1 measures for the entire system

A place to ask questions about methods in Orange and how they are used and other general support.

Precision, recall and F1 measures for the entire system

Postby re832003 » Fri Jul 20, 2012 18:10

Hi,

I know that we can compute precision, recall and F1 measures using

Orange.evaluation.scoring.Precision()
Orange.evaluation.scoring.Recall()
Orange.evaluation.scoring.F1()

and that each of these methods takes the output of a confusionMatrix that worked for binary classification unless the class index is determined.

I have a classification problem with 5 classes and setting the class index in the confusionMatrix method

Orange.evaluation.scoring.confusion_matrices(res, data.domain.class_var.values.index(c))[0]

gives me the confusion matrix of EACH class individually so I end up with something like:

TP: 9, FP: 7, FN: 8.0, TN: 76
TP: 5, FP: 6, FN: 2.0, TN: 87
TP: 1, FP: 4, FN: 7.0, TN: 88
TP: 42, FP: 15, FN: 16.0, TN: 27
TP: 4, FP: 7, FN: 6.0, TN: 83

I want ONE confusionMatrix for all classes so that I can compute precision, recall and F1 measures for the whole data.

Is that possible in Orange?

Many thanks

Re: Precision, recall and F1 measures for the entire system

Postby Ales » Fri Jul 27, 2012 9:39

re832003 wrote:I want ONE confusionMatrix for all classes so that I can compute precision, recall and F1 measures for the whole data.

Is that possible in Orange?
No. Those measures only work on individual binary confusion matrices.


Return to Questions & Support



cron