gauss_bugs: Bugs code for Gaussian response

View source: R/simulateabn.R

gauss_bugsR Documentation

Bugs code for Gaussian response

Description

Bugs model for a normal distributed response variable X \sim \mathcal{N}(\mu,\,\sigma^{2}).

Usage

gauss_bugs(nodename, nodesintercept, parentnames, parentcoefs, std)

gauss_bugsGroup(
  nodename,
  nodesintercept,
  parentnames,
  parentcoefs,
  sigma,
  sigma_alpha
)

Arguments

nodename

character string of response variable name.

nodesintercept

overall mean of response. Parameter from fixed-effects intercept.

parentnames

single character string (for one parent) or vector of characters (for multiple parent nodes) with parent node (predictor variables) names.

parentcoefs

overall slope for each predictor (parent node) variable (fixed-effects).

std

integer with standard deviation of response variable that will be converted to precision (see Details).

sigma

within-group variance. Parameter from random-effects residual.

sigma_alpha

between-group variance. Parameter from random-effects intercept.

Details

The variance of the normal distribution is \frac{1}{\tau}.

Value

Bugs model returned as stdout.

Functions

  • gauss_bugsGroup(): Bugs code for Gaussian response with varying intercept

See Also

makebugs simulateAbn

Examples

gauss_bugs(nodename = "a",
           parentnames = c("b", "c"),
           nodesintercept = c(0.318077),
           parentcoefs = list("b"=c(b=0.3059395),
                              "c"=c(c=0.5555)),
           std = c(0.05773503))

abn documentation built on Nov. 3, 2023, 5:08 p.m.