Skip to contents

Default method used for interface using brms

Usage

# Default S3 method
epidist(
  data,
  formula = mu ~ 1,
  family = lognormal(),
  prior = NULL,
  fn = brms::brm,
  ...
)

Arguments

data

An object with class corresponding to an implemented model.

formula

An object of class stats::formula or brms::brmsformula (or one that can be coerced to those classes). A symbolic description of the model to be fitted. A formula must be provided for the distributional parameter mu, and may optionally be provided for other distributional parameters.

family

A description of the response distribution and link function to be used in the model. Every family function has a link argument allowing users to specify the link function to be applied on the response variable. If not specified, default links are used. For details of all supported families see brmsfamily(). Commonly used, such as lognormal(), are also reexported as part of epidist.

prior

One or more brmsprior objects created by brms::set_prior() or related functions. These priors are passed to epidist_prior() in the prior argument.

fn

The internal function to be called. By default this is brms::brm() which performs inference for the specified model. Other options are brms::make_stancode() which returns the Stan code for the specified model, or brms::make_standata() which returns the data passed to Stan. These two later options may be useful for model debugging and extensions.

...

Additional arguments passed to fn method.

See also

Other fit: epidist()