Skip to content

Commit

Permalink
Merge pull request #122 from stan-dev/loo_epred
Browse files Browse the repository at this point in the history
add loo_epred
  • Loading branch information
jgabry authored Apr 11, 2024
2 parents d2a51bc + e130d81 commit 5f6b787
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions R/loo-functions.R
Original file line number Diff line number Diff line change
Expand Up @@ -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).
Expand All @@ -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, ...) {
Expand Down

0 comments on commit 5f6b787

Please sign in to comment.