% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/ppc.R
\name{plot.bdeb_prediction}
\alias{plot.bdeb_prediction}
\title{Plot Posterior Predictive Trajectories}
\usage{
\method{plot}{bdeb_prediction}(x, n_draws = 100, ...)
}
\arguments{
\item{x}{A \code{bdeb_prediction} object.}

\item{n_draws}{Maximum number of trajectories to overlay.  Default 100.}

\item{...}{Unused.}
}
\value{
A \link[ggplot2:ggplot]{ggplot2::ggplot} object.
}
\description{
Overlays a sample of the posterior trajectory draws stored in a
\code{bdeb_prediction} object.
}
\examples{
\donttest{
if (requireNamespace("cmdstanr", quietly = TRUE) &&
    nzchar(tryCatch(cmdstanr::cmdstan_path(), error = function(e) ""))) {
  data(eisenia_growth)
  dat <- bdeb_data(growth = eisenia_growth[eisenia_growth$id == 1, ])
  fit <- bdeb_fit(bdeb_model(dat, type = "individual"),
                  chains = 2, iter_warmup = 200, iter_sampling = 200,
                  refresh = 0)
  plot(predict(fit), n_draws = 50)
}
}
}
