c_chains_to_dataframe: Obtain data frame representation of measure from list of...

View source: R/c_chains_to_dataframe.R

c_chains_to_dataframeR Documentation

Obtain data frame representation of measure from list of coupled chains

Description

From coupled chains, presumably generated via sample_coupled_chains, and a choice of integers k and m, the function constructs a data frame representation of an empirical signed measure, i.e.

\hat{π}(dx) = ∑_{n=1}^N ω_n δ_{Z_n}(dx)

The function returns a data frame with first column "rep" indicating index of coupled chain, second column "MCMC" indicating whether atom is part of the "MCMC" part of the signed measure (1) or the bias correction part (0) third column "weight" indicating weights, remaining columns "atom.1", "atom.2", etc containing components of the atoms

Usage

c_chains_to_dataframe(c_chains, k, m, dopar = FALSE, prune = TRUE)

Arguments

c_chains

A list containing coupled chains generated by sample_coupled_chains.

k

An integer at which to start computing the signed measure; should be less than m

m

A time horizon: should be less than the length of the chains; typically the same m that was used in the call to sample_coupled_chains, or a smaller value

dopar

Boolean (default to FALSE) indicating whether to perform calculation using registered parallel cores

Value

A data frame


pierrejacob/debiasedmcmc documentation built on Aug. 22, 2022, 12:41 a.m.