space_omega_priors: Generate evenly spaced priors for candidate breakpoints

View source: R/priors.R

space_omega_priorsR Documentation

Generate evenly spaced priors for candidate breakpoints

Description

This helper function generates a list of prior_normal objects for omega (breakpoint locations) that are evenly spaced across the range of your time variable tau. This is highly recommended when using smoothbp_ss() to ensure the candidate breakpoints cover the entire domain without clumping.

Usage

space_omega_priors(K, tau_min, tau_max)

Arguments

K

Number of candidate breakpoints.

tau_min

Minimum value of the time/covariate variable.

tau_max

Maximum value of the time/covariate variable.

Details

For hierarchical models where omega has random effects (e.g., ~ 1 + (1 | group)), this function automatically names the prior (Intercept) so it applies correctly to the global market mean, while the random effects are handled automatically by the sigma_re_om shrinkage variance.

Value

A list of length K containing prior specifications for omega.


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