ModelFit object, output from sampling

ModelFit object, output from sampling

Public fields

standata

The original data that was used to prepare the model

cmdstanmcmc

CmdStanMCMC object

Methods

Public methods


Method new()

Create a new ModelFit You probably don't want to call this

Usage

ModelMCMC$new(standata, cmdstanmcmc)

Arguments

standata

Data that were used to generate the samples

cmdstanmcmc

cmdstanr::CmdStanMCMC output by model

Returns

A new ModelFit object. Estimate the LOO score


Method loo()

Usage

ModelMCMC$loo(cores = 1)

Arguments

cores

int

Returns

A loo::psis_loo object create voxel tuning function posterior


Method make_vtf0()

Usage

ModelMCMC$make_vtf0(cores = 1)

Arguments

cores

integer number of cores over which to parallelize

Returns

posterior::draws_array, Likelihood function


Method .lfun()

Usage

ModelMCMC$.lfun(data_i, draws)

Arguments

data_i

single row of data

draws

posterior

Returns

The likelihood of a single observation Log-Likelihood function


Method .llfun()

Usage

ModelMCMC$.llfun(data_i, draws)

Arguments

data_i

single row of data

draws

posterior

Returns

The log-likelihood of a single observation


Method clone()

The objects of this class are cloneable with this method.

Usage

ModelMCMC$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.