logScoreNormalOffline: Normal-inverse-gamma (with g-prior) Log marginal likelihood...

Description Usage Arguments Details Value See Also

View source: R/score-normal.R

Description

Compute the log marginal likelihood of the supplied Bayesian Network.

Usage

1
2
  logScoreNormalOffline(x, logScoreParameters,
    cache = new.env(hash = T), checkInput = T)

Arguments

x

An object of class "bn". The Bayesian Network by for which the marginal likelihood is computed.

logScoreParameters

A list with the following components:

data

A matrix with columns giving the values of each random variable.

nl

A numeric vector of length nNodes(currentBN), specifying the number of levels that each random variable takes.

cache

Optionally, provide an environment with cached local scores for this data.

checkInput

A logical of length 1, specifying whether to check the inputs to the function.

Details

This function is an alternative interface to logScoreNormal. This interface is required by the MCMC sampler.

Value

A numeric vector of length 1, giving the log marginal likelihood. The environment 'cache' will also be updated because its scope is global.

See Also

logScoreNormal, logScoreNormalIncremental


rjbgoudie/structmcmc documentation built on Nov. 3, 2020, 3:41 a.m.