prior: Build a joint prior for bayesPO model parameters

View source: R/prior-class.R

priorR Documentation

Build a joint prior for bayesPO model parameters

Description

Constructor for bayesPO_prior objects, which is used in the bayesPO_fit function. The generated prior is so that Beta, Delta and LambdaStar are indepdendent a priori.

Usage

prior(beta, delta, lambdaStar)

Arguments

beta

An S4 object whose class inherits from BetaDeltaPrior.

delta

An S4 object whose class inherits from BetaDeltaPrior.

lambdaStar

An S4 object whose class inherits from LambdaStarPrior.

Value

A bayesPO_prior object with the adequate slots. It is ready to be included in a model via the bayesPO_model function.

See Also

fit_bayesPO, NormalPrior, GammaPrior and bayesPO_model.

Examples

# Let us say there are 3 intensity covariates and 4 observability covariates.
# One more element is included in both sets due to the intercepts.
new_prior <- prior(
  NormalPrior(rep(0, 4), 10 * diag(4)),
  NormalPrior(rep(0, 5), 10 * diag(5)),
  GammaPrior(0.0001, 0.0001)
)

bayesPO documentation built on May 29, 2024, 8:33 a.m.