BrierScore(...)
"BrierScore"(x, scaled = FALSE, ...)
"BrierScore"(resp, pred, scaled = FALSE, ...)
It's calculated as $$\frac{1}{n} \cdot \sum_{i=1}^{n}\left ( p_{i}-o_{i} \right )^2 \; \; \; \textup{where} \; p_{i} predicted probability \; \textup{and} \; o_{i} observed value out of (0,1)$$
The lower the Brier score is for a set of predictions, the better the predictions are calibrated. Note that the Brier score, in its most common formulation, takes on a value between zero and one, since this is the largest possible difference between a predicted probability (which must be between zero and one) and the actual outcome (which can take on values of only 0 and 1). (In the original (1950) formulation of the Brier score, the range is double, from zero to two.)
Conf
r.glm <- glm(Survived ~ ., data=Untable(Titanic), family=binomial)
BrierScore(r.glm)
Run the code above in your browser using DataLab