Skip to content
EvalSuite
Documentation menu

Classification

F-beta score

Implementedclassification.fbeta

Definition

Weighted harmonic mean of precision and recall; beta > 1 favours recall, beta < 1 precision.

Formula

(1+β²)·TP / ((1+β²)·TP + β²·FN + FP)

Range: [0, 1]

Inputs and outputs

  • y_true: array of class labels
  • y_pred: array of predicted labels

Returns: MetricResult

Assumptions

No assumptions beyond valid, aligned inputs of the documented types.

Limitations

No metric-specific limitations are documented yet. Interpret the value alongside the task, data, and other metrics.

Python API

PythonSince v0.1.0
import evalsuite as es

es.fbeta(y_true, y_pred, beta=2)

References

  1. van Rijsbergen CJ. Information Retrieval. 2nd ed. Butterworths; 1979.

Implementation status