See the methods in the rstanarm package for examples.
loo_linpred(object, ...)loo_predict(object, ...)
loo_predictive_interval(object, ...)
loo_pit(object, ...)
# S3 method for default
loo_pit(object, y, lw, ...)
The object to use.
Arguments passed to methods. See the methods in the rstanarm package for examples.
For the default method of loo_pit
, a vector of \(y\) values
the same length as the number of columns in the matrix used as
object
.
For the default method of loo_pit
, a matrix of log-weights
of the same length as the number of columns in the matrix used as
object
.
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.
loo_predictive_interval
methods should return a two-column matrix
formatted in the same way as for predictive_interval
.
Guidelines and recommendations for developers of R packages interfacing with Stan and a demonstration getting a simple package working can be found in the vignettes included with rstantools and at http://mc-stan.org/rstantools/articles/.