Learn R Programming

randomMachines (version 0.1.1)

brier_score: Brier Score function

Description

Calculate the Brier Score for a set of predicted probabilities and observed outcomes. The Brier Score is a measure of the accuracy of probabilistic predictions. It is commonly used in the evaluation of predictive models.

Usage

brier_score(prob, observed, levels)

Value

Returns the Brier Score, a numeric value indicating the accuracy of the predictions.

Arguments

prob

predicted probabilities

observed

\(y\) observed values (it assumed that the positive class is coded is equal to one and the negative 0)

levels

A string vector with the original levels from the target variable