Did you know ... Search Documentation:
Pack auc -- prolog/auc.pl
PublicShow source

This module computes the Area Under the Receiving Operating Characteristics and Precision Recall curves using the method of Davis, Jesse, and Mark Goadrich. "The relationship between Precision-Recall and ROC curves." Proceedings of the 23rd international conference on Machine learning. ACM, 2006.

author
- Fabrizio Riguzzi
license
- Artistic License 2.0
 compute_areas(+LG:list, -AUCROC:float, -ROC:list, -AUCPR:float, -PR:list) is det
The predicate takes as input
  • a list LG of pairs probability-literal in ascending order on probability where the literal can be an Atom (indicating a positive example) or \+ Atom, indicating a negative example while the probability is the probability of Atom of being true

    The predicate returns

  • AUCROC: the size of area under the ROC curve
  • ROC: the ROC curve as a list of points that are couples of the form x-y
  • AUCPR: the size of the area under the PR curve
  • PR: the PR curve as a list of points that are couples of the form x-y
 compute_areas_diagrams(+LG:list, -AUCROC:float, -ROC:dict, -AUCPR:float, -PR:dict) is det
The predicate takes as input
  • a list LG of pairs probability-literal in ascending order on probability where the literal can be an Atom (indicating a positive example) or \+ Atom, indicating a negative example while the probability is the probability of Atom of being true

    The predicate returns

  • AUCROC: the size of the area under the ROC curve
  • ROC: the ROC curve as a dict that can be visualized with the c3 renderer of SWISH
  • AUCPR: the size of the area under the PR curve
  • PR: the PR curve as a dict that can be visualized with the c3 renderer of SWISH See http://cplint.lamping.unife.it/example/exauc.pl for an example
 compute_maxacc(+LG:list, -MaxAcc) is det
The predicate takes as input
  • a list LG of pairs probability-literal in ascending order on probability where the literal can be an Atom (indicating a positive example) or \+ Atom, indicating a negative example while the probability is the probability of Atom of being true

    The predicate returns

  • MaxAcc: the maximum obtainable accuracy See http://cplint.lamping.unife.it/example/exauc.pl for an example