findShifts: findShifts

Description Usage Arguments Details Value

View source: R/findShifts.R

Description

Returns the node numbers of nodes that have been scaled in a specified fraction of iterations in the posterior of a BayesTraits MCMC analysis using variable rates of a variable transformation.

Usage

1
findShifts(PP, scalar, threshold)

Arguments

PP

The postprocessor (getRates) output.

scalar

The scalar to find and plot from the post processo:r

- delta

- lambda

- kappa

- node

- branch

- rate (returns both branch and node scalars).

threshold

The fraction of samples a scalar needs to be present in to be returned. e.g. if 0.5, then all scalars present in the posterior more than 50% of the time will be returned.

Details

Works for rate scalars, and transformations. Also can return branch scalars, if the specified scalar is "rate". Only looks at the position that scalars are placed, not the cumulative effects of these scalars (i.e. if a node is never given a scalar itself but is affected by a scalar on an ancestral node, it will not be identified by this function).

Value

A vector of node/edge numbers (depending on scalar) that are scaled over the threshold value.


hferg/bayestraitr documentation built on May 28, 2019, 8:55 p.m.