Learn R Programming

qbrms (version 1.0.1)

conditional_effects.qbrms_fit: Conditional effects for qbrms Gaussian models

Description

Conditional effects for qbrms Gaussian models

Usage

# S3 method for qbrms_fit
conditional_effects(
  object,
  effects = NULL,
  spaghetti = FALSE,
  ndraws = 200L,
  n_points = 100L,
  at = list(),
  seed = NULL,
  prob = 0.95,
  ...
)

Value

An object of class "qbrms_conditional_effects" containing a list with one element per effect. Each element is a data frame with columns for the predictor values, point estimates (estimate__), and credible interval bounds (lower__, upper__).

Arguments

object

A qbrms fit object (Gaussian).

effects

Character vector: names of predictors to vary. Supports simple two-way interactions "num:fac" or "fac:num" where one is numeric and the other factor.

spaghetti

Logical; if TRUE draw per-draw "spaghetti" lines. If FALSE, draw a mean line with a credible-interval ribbon.

ndraws

Number of joint coefficient draws for uncertainty (default 200).

n_points

Size of the x-grid across the observed range (default 100).

at

Optional named list of covariate values to hold constant.

seed

Optional integer seed for reproducibility.

prob

Interval probability for ribbons (default 0.95).

...

Ignored.