GaussianInvWishart {bbricks}R Documentation

Create objects of type "GaussianInvWishart".

Description

Create an object of type "GaussianInvWishart", which represents the Gaussian and Inverse-Wishart conjugate structure:

x \sim Gaussian(mu,Sigma)

Sigma \sim InvWishart(v,S)

mu is known. Gaussian() is the Gaussian distribution. See ?dGaussian and ?dInvWishart for the definition of the distributions.
The created object will be used as a place for recording and accumulating information in the related inference/sampling functions such as posterior(), posteriorDiscard(), MAP(), marginalLikelihood(), dPosteriorPredictive(), rPosteriorPredictive() and so on.

Usage

GaussianInvWishart(
  objCopy = NULL,
  ENV = parent.frame(),
  gamma = list(mu = 0, v = 3, S = 1)
)

Arguments

objCopy

an object of type "GaussianInvWishart". If "objCopy" is not NULL, the function create a new "GaussianInvWishart" object by copying the content from objCopy, otherwise this new object will be created by using "ENV" and "gamma". Default NULL.

ENV

environment, specify where the object will be created.

gamma

list, a named list of parameters, gamma=list(mu,v,S). Where gamma$mu is the known mean vector of x, gamma$v and gamma$S are the prior degree of freedom and scale of Sigma.

Value

An object of class "GaussianInvWishart".

References

Gelman, Andrew, et al. Bayesian data analysis. CRC press, 2013.

See Also

posterior.GaussianInvWishart,posteriorDiscard.GaussianInvWishart,MAP.GaussianInvWishart,MPE.GaussianInvWishart,marginalLikelihood.GaussianInvWishart,rPosteriorPredictive.GaussianInvWishart,dPosteriorPredictive.GaussianInvWishart ...

Examples

obj <- GaussianInvWishart(gamma=list(mu=c(-1.5,1.5),v=3,S=diag(2)))
obj #print the content

[Package bbricks version 0.1.4 Index]