powered by
Harmonic mean of precision and recall.
f1_score(y_true, y_pred, positive = NULL)
numeric f1 score
true labels
predicted labels
positive class label
Provides functionality for f1_score operations.
VectorForgeML-package
y_true <- c(1,0,1,1) y_pred <- c(1,0,0,1) f1_score(y_true, y_pred)
Run the code above in your browser using DataLab