Skip to content

Fix brier() and logloss() on a probability vector - #63

Merged
ielbadisy merged 1 commit into
mainfrom
fix-brier-vector
Nov 14, 2026
Merged

ielbadisy merged 1 commit into
mainfrom
fix-brier-vector

Conversation

@ielbadisy

Copy link
Copy Markdown
Owner

brier(truth, p) with a plain numeric vector returned mean(p^2) because the coerced matrix had no column names, and logloss() returned NA. A vector is now read as the probability of the second (positive) level for a binary outcome; a vector with a multiclass outcome is an error. Adds tests.

@ielbadisy
ielbadisy merged commit deeb5ff into main Nov 14, 2026
@ielbadisy
ielbadisy deleted the fix-brier-vector branch November 14, 2026 16:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant