ec_lmd_NR {echoice2}R Documentation

Obtain Log Marginal Density from draw objects

Description

This is a helper function to quickly obtain log marginal density from a draw object

Usage

ec_lmd_NR(est)

Arguments

est

'echoice2' draw object

Details

Draws are split in 4 equal parts from start to finish, and LMD is computed for each part. This helps to double-check convergence.

Value

tibble with LMDs (first 25% of draws, next 25% of draws, ...)

Examples

data(icecream)
#run MCMC sampler (use way more than 50 draws for actual use)
icecream_est <- icecream %>% dplyr::filter(id<100) %>% vd_est_vdm(R=20, cores=2)
#obtain LMD by quartile of draws
ec_lmd_NR(icecream_est)


[Package echoice2 version 0.2.4 Index]