get.loglik: Pointwise log-likelihood for the change-point model

View source: R/helper.R

get.loglikR Documentation

Pointwise log-likelihood for the change-point model

Description

Provides the pointwise log-likelihood contribution for each datapoint and simulation which is required to compute the Pseudo-Marginal Likelihood (PML) and Widely Applicable Information Criterion (WAIC).

Usage

get.loglik(df, lambda_df, changepoint_df)

Arguments

object

of class "changepoint".

chng.numvalue

indicating the changepoint model to plotted, default is "all", in which all posterior simulations will be used.

Value

a matrix of size nSims by n_obs (number of simulations and number of observations respectively).

Examples

## Not run: 
Can take a considerable time to evaulate.
log.lik.df <- get.loglik(Collapsing_Model)

## End(Not run)


Philip-Cooney/PiecewiseChangepoint documentation built on Sept. 10, 2023, 9:49 p.m.