make.gbm {geiger}R Documentation

tailor reversible-jump Markov chain Monte Carlo sampling

Description

controlling reversible-jump Markov chain Monte Carlo sampling

Usage

make.gbm(phy, dat, SE=NA, type = c("bm", "rbm", "jump-bm", "jump-rbm"), ...)

Arguments

phy

a phylogenetic tree of class 'phylo'

dat

a named vector of continuous trait values, associated with each species in phy

SE

a named vector of standard errors for each trait value; applied to all trait values if given a single value

type

the class of model to use (see rjmcmc.bm)

...

arguments passed internally to control other settings (see Details)

Details

The argument ... controls the substitution of default settings for Markov-chain Monte Carlo sampling. Below are the settings that are controllable by the user. These parameters and their default settings can also be found with an empty call to the function (e.g., make.gbm()).

measurement error (SE): one of the arguments necessary for running rjmcmc.bm is SE, which is a statement about the error associated with the values given in dat. Measurement error (whose argument is SE) can be a named vector of numeric values (including NA) or a single value (including NA). If given as a vector, SE must have names that correspond to the those found for dat. If given a single value for SE, the sampler will apply that value of measurement error to all tips in the tree. If NA appears for the measurement error for any species, SE becomes an additional parameter of the model: this density is consequently sampled by rjmcmc.bm. The default for rjmcmc.bm is to estimate a single SE (which is applied to all species).

control settings: default settings for each control parameter are given below. Note that for the discrete random variables (for which dlnSHIFT and dlnJUMP) apply, certain criteria must be met if the user prefers to supply a different prior density. The function dcount is useful for building a custom prior density function for discrete variables.

Value

The items that can be tailored in the resulting control object are as follows:

\bold{method}

default direct; this defines the implementation for computing model likelihood (currently with only the default available)

\bold{constrainSHIFT}

default FALSE; if integer given, this constrains the number of local clocks in the diffusive process

\bold{constrainJUMP}

default FALSE; if integer given, this constrains the number of pulses in the jump process

\bold{dlnSHIFT}

default dcount(0:(nn - 1), FUN = dpois, lambda = log(2)), where nn is the number of branches in the tree; this controls the prior density on the number of shifts between local clocks in the tree (and applies only if the type argument to rjmcmc.bm is "rbm" or "jump-rbm") and if constrainSHIFT is FALSE)

\bold{dlnJUMP}

default dcount(0:nn, FUN = dlunif, min = 0, max = nn, dzero = 0.5), where nn is the number of branches in the tree; this controls the prior density on the number of evolutionary pulses across the tree (and applies only if the type argument to rjmcmc.bm is "jump-bm" or "jump-rbm" and if constrainJUMP is FALSE)

\bold{dlnRATE}

default function (x) dexp(x, rate = 1/(10^3), log = TRUE); this defines the prior density on rate scalars

\bold{dlnSE}

default function (x) dexp(x, rate = 1/(10^3), log = TRUE); this defines the prior density on measurement error

\bold{dlnPULS}

default function (x) dexp(x, rate = 1/(10^3), log = TRUE); this defines the prior density on jump variance

\bold{dlnROOT}

default function (x) dunif(x, min=-10^3, max=10^3, log=TRUE); this defines the prior density on root state

\bold{rate.lim}

default list(min=0, max=Inf); this defines the numerical limits on the rate scalars

\bold{se.lim}

default list(min=0, max=Inf); this defines the numerical limits on the measurement error

\bold{root.lim}

default list(min=-Inf, max=Inf); this defines the numerical limits on the root state

\bold{jump.lim}

default 1; determines the number of jumps permissible along each branch (1 is currently supported)

\bold{excludeSHIFT}

default c(); if this argument is not empty, these are branches (specified by numeric node-identifiers) which cannot be chosen for a novel local clock

\bold{excludeJUMP}

default c(); if this argument if not empty, these are branches (specified by numeric node-identifiers) which cannot be chosen for an evolutionary pulse

\bold{bm.jump}

default 0.5; this defines the ratio between proposals for the diffusion and jump processes (0.5 is perfectly balanced)

\bold{mergesplit.shift}

default 0.5; this defines the ratio between proposals that scale model complexity and those that do not

\bold{tune.scale}

default 0.65; this defines the ratio between proposals that modify the model branchwise versus treewide

\bold{slide.mult}

default 0.25; this defines the ratio between sliding window and multiplier proposals

\bold{prob.dimension}

default 0.65; this defines the proportion of proposals used to modify model dimensionality

\bold{prob.effect}

default 0.3; this defines the proportion of proposals that do not alter dimensionality

\bold{prob.SE}

default 0.03; this defines the proportion of proposals that alter the (unknown) measurement error

\bold{prob.root}

default 0.02; this defines the proportion of proposals that alter the root state

\bold{prop.width}

default 1; this defines the proposal width used for multiplier and sliding-window proposals

\bold{simple.start}

default TRUE; this determines whether to start the MCMC sampler with minimal dimensionality

\bold{filebase}

default "result"; this defines a 'base' filename for the output

Author(s)

JM Eastman

See Also

rjmcmc.bm


[Package geiger version 2.0.11 Index]