smoothbp_priors: Collect priors for all model parameters

View source: R/priors.R

smoothbp_priorsR Documentation

Collect priors for all model parameters

Description

Each argument accepts either:

  • A single prior_normal() applied to all coefficients of that parameter, or

  • A named list mapping coefficient names (matching column names of the design matrix) to individual prior_normal() objects.

Usage

smoothbp_priors(
  b0 = prior_normal(0, 10),
  b1 = prior_normal(0, 2),
  deltas = prior_normal(0, 2),
  omega = prior_normal(3, 2, lb = 0),
  rho = prior_normal(3, 2, lb = 0),
  sigma = prior_invgamma(1, 1),
  sigma_u = prior_invgamma(1, 1),
  sigma_re_om = prior_invgamma(1, 1),
  sigma_re_b1 = prior_invgamma(1, 1),
  sigma_re_deltas = prior_invgamma(1, 1)
)

Arguments

b0

Prior(s) for b0 regression coefficients.

b1

Prior(s) for b1 regression coefficients.

deltas

Prior(s) for slope change coefficients (one list per segment).

omega

Prior(s) for omega coefficients (one list per segment).

rho

Prior(s) for rho coefficients (one list per segment).

sigma

prior_invgamma() for residual SD.

sigma_u

prior_invgamma() for random-effect SD.

sigma_re_om

prior_invgamma() for random-effect SD on omega.

sigma_re_b1

prior_invgamma() for random-effect SD on b1.

sigma_re_deltas

prior_invgamma() for random-effect SD on deltas.

Details

For multi-breakpoint models, deltas, omega, and rho can also be lists of prior specifications (one per breakpoint slot). If a single specification is provided, it is applied to all slots.

Value

A smoothbp_priors list.


smoothbp documentation built on June 14, 2026, 9:06 a.m.