From e130d81b5c48a08e9962ce73e59c724c88caaf04 Mon Sep 17 00:00:00 2001 From: Aki Vehtari Date: Mon, 8 Apr 2024 15:25:19 +0300 Subject: [PATCH] add loo_epred --- R/loo-functions.R | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/R/loo-functions.R b/R/loo-functions.R index 184dd51..89a2a36 100644 --- a/R/loo-functions.R +++ b/R/loo-functions.R @@ -7,9 +7,9 @@ #' @template args-object #' @template args-dots #' -#' @return `loo_predict()`, `loo_linpred()`, and `loo_pit()` -#' (probability integral transform) methods should return a vector with length -#' equal to the number of observations in the data. +#' @return `loo_predict()`, `loo_epred()`, `loo_linpred()`, and `loo_pit()` +#' (probability integral transform) methods should return a vector with +#' length equal to the number of observations in the data. #' For discrete observations, probability integral transform is randomised to #' ensure theoretical uniformity. Fix random seed for reproducible results #' with discrete data. For more details, see Czado et al. (2009). @@ -26,6 +26,12 @@ loo_linpred <- function(object, ...) { UseMethod("loo_linpred") } +#' @rdname loo-prediction +#' @export +loo_epred <- function(object, ...) { + UseMethod("loo_epred") +} + #' @rdname loo-prediction #' @export loo_predict <- function(object, ...) {