transform_gibbs_samples: Transformation of Gibbs samples

View source: R/model_fitting.R

transform_gibbs_samplesR Documentation

Transformation of Gibbs samples

Description

This function normalizes, burns and thins the Gibbs samples.

Usage

transform_gibbs_samples(gibbs_samples, R, B, Q, normalization)

Arguments

gibbs_samples

The output of gibbs_sampling, i.e. a list of Gibbs samples for

  • Sigma,

  • alpha (if P_f>0),

  • s, z, b, Omega (if P_r>0).

R

The number of iterations of the Gibbs sampler.

B

The length of the burn-in period, i.e. a non-negative number of samples to be discarded.

Q

The thinning factor for the Gibbs samples, i.e. only every Qth sample is kept.

normalization

An object of class RprobitB_normalization, which can be created via RprobitB_normalization.

Value

A list, the first element gibbs_sampes_raw is the input gibbs_samples, the second element is the normalized, burned, and thinned version of gibbs_samples called gibbs_samples_nbt. The list gets the class RprobitB_gibbs_samples.


RprobitB documentation built on Nov. 10, 2022, 5:12 p.m.