gbi_MCMC_iters: Minimum number of MCMC iterations needed for...

View source: R/gbi_null_models.R

gbi_MCMC_itersR Documentation

Minimum number of MCMC iterations needed for Group-by-Individuals randomisations.

Description

Uses an analytically-derived equation to estimate the minimum number of MCMC iterations required to generate a target number of effective samples from the null. This function should only be used as a rough guide before running computationally intensive randomisations with gbi_MCMC. The true number of MCMC iterations may need to be much higher, so MCMC diagnostics should always be used to verify that samples are reliable.

Usage

gbi_MCMC_iters(gbi, target_samples = 1000, quiet = FALSE)

Arguments

gbi

A group by individual matrix

target_samples

Target number of effective samples

quiet

Logical, should messages produced by the function be suppressed?

Value

The minimum number of MCMC iterations required to generate target_samples effective samples.


MNWeiss/aninet documentation built on Jan. 31, 2023, 3:55 a.m.