computeLogLik: Compute log-likelihood

View source: R/posterior_diagnostics.R

computeLogLikR Documentation

Compute log-likelihood

Description

Compute log-likelihood

Usage

computeLogLik(out, verbose = FALSE, addthin = 1)

Arguments

out

Output from BSTFA or BSTFAfull.

verbose

Logical scalar indicating whether to print status of the log-likelihood computation. Default is FALSE.

addthin

Numeric scalar indicating the number of additional draws to thin by to reduce the computation time. Default is 1 (no additional thinning).

Value

A matrix of size n.times*n.locs by draws log-likelihood values for each observation and each posterior draw.

Author(s)

Adam Simpson and Candace Berrett

Examples

data(out.sm)
attach(out.sm)
loglik <- computeLogLik(out.sm, addthin=2)

BSTFA documentation built on Aug. 28, 2025, 9:09 a.m.