Weighted average of (unscaled) unit normal deviance. This equals the weighted mean-squared error, see e.g. [1]. The smaller the deviance, the better.
deviance_normal(actual, predicted, w = NULL, ...)
Observed values.
Predicted values.
Optional case weights.
Further arguments passed to mse
.
A numeric vector of length one.
[1] Jorgensen, B. (1997). The Theory of Dispersion Models. Chapman & Hall/CRC. ISBN 978-0412997112.
# NOT RUN {
deviance_normal(1:10, c(1:9, 12))
deviance_normal(1:10, c(1:9, 12), w = rep(1, 10))
deviance_tweedie(1:10, c(1:9, 12), tweedie_p = 0)
deviance_normal(1:10, c(1:9, 12), w = 1:10)
# }
Run the code above in your browser using DataLab