Components: Specify priors for the components in a Mix prior.

View source: R/SpecPrior-generators.R

ComponentsR Documentation

Specify priors for the components in a Mix prior.

Description

In normal usage, it is better to accept the default prior for the components than to specify it explicitly. End users are therefore unlikely to need this function.

Usage

Components(scale = HalfT())

Arguments

scale

An object of class HalfT.

Details

A Mix prior treats an interaction as a mixture of normal distributions. The means for these normal distributions are formed by multiplying a component for each dimension other than the 'along' dimension (typically the time dimension). Each element of these components has a normal prior with mean 0 and standard deviation scaleComponent. The prior for scaleComponent can be set using the scale argument.

Let s be the standard deviation of data y, or of log(y) in the case of a Poisson model without exposure. Let m be the mult argument. Then the default value for scale parameter in the half-t distribution is

Model Default
Poisson with exposure m 0.5
Poisson without exposure ms 0.5
binomial m 0.5
normal ms 0.5

Value

An object of class Components.

See Also

Mixture priors are specified using Mix. The weights in a mixture prior are specified using Weights.

Examples

Components()
## A tighter prior on 'scaleComponent'
Components(scale = HalfT(scale = 0.25))


StatisticsNZ/demest documentation built on Nov. 2, 2023, 7:56 p.m.