
Create a `beast2_options` structure for the `mcbette` R package
Source:R/create_mcbette_beast2_options.R
create_mcbette_beast2_options.RdCreate a `beast2_options` structure to be used for the `mcbette` R package, which is a package that allows one to do model comparison. The generated filenames indicating `mcbette` usage, as well as the correct BEAST2 binary/executable type
Usage
create_mcbette_beast2_options(
input_filename = beastier::create_temp_input_filename(),
output_state_filename = beastier::create_temp_state_filename(),
rng_seed = NA,
n_threads = NA,
use_beagle = FALSE,
overwrite = TRUE,
beast2_bin_path = beastier::get_default_beast2_bin_path(),
verbose = FALSE
)Arguments
- input_filename
the name of a BEAST2 input XML file. This file usually has an
.xmlextension. Use create_temp_input_filename to create a temporary filename with that extension.- output_state_filename
name of the
.xml.statefile to create. Use create_temp_state_filename to create a temporary filename with that extension.- rng_seed
the random number generator seed of the BEAST2 run. Must be a non-zero positive integer value or NA. If
rng_seedis NA, BEAST2 will pick a random seed- n_threads
the number of computational threads to use. Use NA to use the BEAST2 default of 1.
- use_beagle
use BEAGLE if present
- overwrite
if TRUE: overwrite the
.logand.treesfiles if one of these exists. If FALSE, BEAST2 will not be started ifthe
.logfile existsthe
.treesfiles existthe
.logfile created by BEAST2 existsthe
.treesfiles created by BEAST2 exist
- beast2_bin_path
name of the BEAST2 binary file (usually simply
beast). Use get_default_beast2_bin_path to get the default BEAST binary file's path- verbose
if TRUE, additional information is displayed, that is potentially useful in debugging
Value
a `beast2_options` structure suitable to be used by the `mcbette` R package, which is a list of all function arguments, of which all elements are checked (by check_beast2_options)
See also
to create a regular (that is, not intended for model comparison) BEAST2 options structure, use create_beast2_options
Examples
check_empty_beaustier_folders()
create_mcbette_beast2_options()
#> $input_filename
#> [1] "/github/home/.cache/beastier/beast2_71c790274bd.xml"
#>
#> $output_state_filename
#> [1] "/github/home/.cache/beastier/beast2_71c3a050c1a.xml.state"
#>
#> $rng_seed
#> [1] NA
#>
#> $n_threads
#> [1] NA
#>
#> $use_beagle
#> [1] FALSE
#>
#> $overwrite
#> [1] TRUE
#>
#> $beast2_path
#> [1] "/github/home/.local/share/beast/bin/beast"
#>
#> $verbose
#> [1] FALSE
#>
check_empty_beaustier_folders()