plot_distribution_tree: Plot the dwelling times distribution of a state in a given...

plot_distribution_treeR Documentation

Plot the dwelling times distribution of a state in a given tree

Description

This functions plots the posterior distribution of a state in the tree used as base_tree on map_posterior_distribution.

The legend shows the colors representing the incidence of state given as parameter in the trees analysize in map. The NA values means that there are no sufficient data to compute the values for the branch given the confidence interval (conf_level parameter). In other words, the branch is not present in a sufficient number of the analysed trees.

Usage

plot_distribution_tree(map, state='all', type='emr', conf_level=95, number_of_ticks=20
                    , tip_states=NULL, fsize=0.7, ftype="i", lwd=3, tip.label=NULL)

Arguments

map

A result of a map_posterior_distribution execution;

state

The state to be plotted. NULL means that the program should consider all states. This makes more sense for "muration rate" then other types of plot.

type

emr for expected markov reward (dwelling times) or lmt for labelled makov transistions (number of transitions). Defaults to emr;

conf_level

An integer representing the confidence level desired, ranging from 0 to 100. Defaults to 95 percent;

number_of_ticks

The number of intervals in which the data will be divided. Defaults to 20;

tip_states

tip states as provided to sfreemap;

fsize

relative font size for tip labels;

ftype

font type - options are "reg", "i" (italics), "b" (bold), or "bi" (bold-italics);

lwd

line width for three branches.

tip.label

A vector containing the tip names. Defaults to NULL, meaning tip names will be get from the phylo object

Value

Returns the tree plotted, with the data used in the plot stored in tree\$maps.

Author(s)

Diego Pasqualin dpasqualin@inf.ufpr.br

See Also

map_posterior_distribution

Examples

sm <- sfreemap(sfreemap.corals.trees, sfreemap.corals.tips, parallel=FALSE)
map <- map_posterior_distribution(sm[[1]], sm, parallel=FALSE)
tree <- plot_distribution_tree(map, state='colonial', tip_states=sfreemap.corals.tips)

dpasqualin/sfreemap documentation built on July 5, 2023, 10:52 a.m.