block.boot: Generate block bootstrap replicates of sampled power...

View source: R/marginal-lhd.R

block.bootR Documentation

Generate block bootstrap replicates of sampled power likelihoods

Description

Generate block bootstrap replicates of sampled power likelihoods

Usage

block.boot(R, p = 0.1, mcmcf = "mcmc.txt", betaf = "beta.txt", preff = "lnL")

Arguments

R

numeric, number of bootstrap replicates

p

numeric, block length, giving as a proportion of the MCMC sample size

mcmcf

character, mcmc output file name

betaf

character, file with beta values

preff

character, prefix for files storing boot replicates

Details

Block bootstrap replicates are generated using the stationary boostrap method of Politis and Romano (1994). The replicates are stored in files named using preff and the replicate number. For example, if preff = "lnL" (the default) then the files are lnL0.txt, lnL1.txt, lnL2.txt, ..., etc, with lnL0.txt corresponding to the original log-likelihood sample. Replicates are stored within the directories corresponding to the appropriate beta values. The collection of files can grow large quickly so you may want to use a small number of replicates (say R = 10 to R = 100).

This function uses code from the boot package by Canty and Ripley.

References

Álvarez-Carretero et al (2022) A species-level timeline of mammal evolution integrating phylogenomic data. Nature, 602: 263–267.

Politis and Romano (1994) The stationary boostrap. J. Am. Stat. Assoc., 89: 1303–1313.

See Also

stepping.stones.boot and tsboot (from the boot package).


dosreislab/mcmc3r documentation built on March 29, 2024, 6:45 p.m.