extract_log_lik: Extract pointwise log-likelihood from a Stan model for a...

View source: R/loo.R

extract_log_likR Documentation

Extract pointwise log-likelihood from a Stan model for a bellreg model

Description

This function extracts the pointwise log-likelihood for a bellreg model.

Usage

extract_log_lik(object, ...)

Arguments

object

an object of the class bellreg.

...

further arguments passed to or from other methods.

Value

a matrix with the pointwise extracted log-likelihood associated with a bellreg model.

Examples


data(faults)
fit <- bellreg(nf ~ lroll, data = faults, approach = "bayes")
loglik <- extract_log_lik(fit)

data(cells)
fit <- zibellreg(cells ~ 1|smoker+gender, data = cells, approach = "bayes", chains = 1, iter = 100)
loglik <- extract_log_lik(fit)




bellreg documentation built on Oct. 23, 2024, 9:06 a.m.