A loo::loo() method that is customized for measrfit objects. This is a
simple wrapper around loo::loo.array(). See the loo package
vignettes for details.
Usage
# S3 method for class 'measrfit'
loo(x, ..., r_eff = NA, force = FALSE)Arguments
- x
A measrfit object.
- ...
Additional arguments passed to
loo::loo.array().- r_eff
Vector of relative effective sample size estimates for the likelihood (
exp(log_lik)) of each observation. This is related to the relative efficiency of estimating the normalizing term in self-normalized importance sampling when using posterior draws obtained with MCMC. If MCMC draws are used andr_effis not provided then the reported PSIS effective sample sizes and Monte Carlo error estimates can be over-optimistic. If the posterior draws are (near) independent thenr_eff=1can be used.r_effhas to be a scalar (same value is used for all observations) or a vector with length equal to the number of observations. The default value is 1. See therelative_eff()helper functions for help computingr_eff.- force
If the LOO criterion has already been added to the model object with
add_criterion(), should it be recalculated. Default isFALSE.
Value
The object returned by loo::loo.array().
