readLog: Read BEAST log files

Description Usage Arguments Value See Also

View source: R/log_utils.R

Description

Read a single BEAST log file and return as a coda "mcmc" object. If filenames contains more than one entry each log file is added as a separate chain and a coda "mcmc.list" object is returned.

Usage

1
2
3
4
5
6
7
readLog(
  filenames,
  burnin = 0.1,
  maxsamples = -1,
  as.mcmc = TRUE,
  burninAsSamples = FALSE
)

Arguments

filenames

The name of the log file to read, or aternatively a vector or list of input log file names.

burnin

Discard this proportion of samples at the start of the chain (if 'burninAsSamples' == FALSE). Otherwise discard this many samples at the start of the chain.

maxsamples

If > 0 stop after reading in this many lines (this option is only for testing and should generally not be used).

as.mcmc

If FALSE then return an object of class "data.frame", else return an "mcmc" object

burninAsSamples

if TRUE burnin is given as the number of samples, if FALSE burnin is a proportion (0 <= burnin < 1) of samples. (default = FALSE).

Value

An "mcmc" object (mcmc) or data frame (data.frame) object containing all of the parameters in the MCMC chain, with the burn-in discarded. If more than one log file was given as input the output will be an "mcmc.list" object (mcmc.list) or a list of data frames (data.frame).

See Also

readSingleLog


laduplessis/beastio documentation built on Dec. 14, 2021, 7:04 p.m.