Learn R Programming

qbrms (version 1.0.1)

prior_build_from_beliefs: Prior Build from Beliefs

Description

Build priors from elicited beliefs (GLM-aware)

Usage

prior_build_from_beliefs(
  formula,
  data,
  family = gaussian(),
  beliefs = list(),
  outcome_location = NULL,
  outcome_interval = NULL,
  outcome_level = 0.95,
  outcome_sd = NULL,
  standardise = TRUE,
  plausible_range = NULL,
  target_coverage = 0.8,
  tune = FALSE,
  seed = NULL
)

Value

An object of class "qbrms_prior_build" containing:

  • priors: A list of prior specifications.

  • prior_code: Character string of R code to reproduce the priors.

  • formula: The (possibly modified) model formula.

  • data: The (possibly standardised) data.

  • diagnostics: Prior predictive diagnostic information.

Arguments

formula

Model formula

data

Data frame

family

Model family

beliefs

List of beliefs about parameters

outcome_location

Expected outcome location

outcome_interval

Expected outcome interval

outcome_level

Confidence level for outcome interval

outcome_sd

Outcome standard deviation

standardise

Whether to standardise predictors

plausible_range

Plausible range for outcomes

target_coverage

Target coverage probability

tune

Whether to tune priors

seed

Random seed