get_ppc_plot: pp_check for loo statistics

View source: R/plot.R

get_ppc_plotR Documentation

pp_check for loo statistics

Description

pp_check for loo statistics

Usage

get_ppc_plot(fit, type, y, yrep, nsamples, draws = NULL, ...)

Arguments

type

One of bayesplot::available_ppc("grouped", invert = TRUE) %>% stringr::str_remove("ppc_")

y

Response vector

yrep

S X N matrix of predicted responses

nsamples

Number of draws. Note that you may want to use all data for summary geoms. e.g., pp_check(fit, type = "ribbon", nsamples = NULL).

draws

(required for loo-type plots) Indices of draws to use.

...

Arguments passed to bayesplot::ppc_type(y, yrep, ...)

Value

A ggplot2 object returned by ⁠tidybayes::ppc_*(y, yrep, ...)⁠.

A string

Author(s)

Jonas Kristoffer Lindeløv jonas@lindeloev.dk


mcp documentation built on May 29, 2024, 6:15 a.m.