# See vignette("rates-selection") for how to use this
# function as part of an analysis pipeline
## MrBayes example
# Load example tree and posterior
data("tree3p")
data("posterior3p")
plot_treerates_sgn(
type = "MrBayes",
tree3p, posterior3p, #MrBayes tree file with data for all partitions
trans = "none",
summary = "mean", #MrBayes specific argument
drop.dummyextant = TRUE, #MrBayes specific argument
clock = 1, #Show rates for clock partition 1
threshold = c("1 SD", "3 SD"), #sets background rate threshold for selection mode
branch_size = 1.5, tip_size = 3, #sets size for tree elements
xlim = c(-450, -260), nbreaks = 8, geo_size = list(3, 3)) #sets limits and breaks for geoscale
if (FALSE) {
## BEAST2 example
tree_clock1 <- system.file("extdata", "Penguins_MCC_morpho_part1", package = "EvoPhylo")
tree_clock1 <- treeio::read.beast(tree_clock1)
posterior <- system.file("extdata", "Penguins_log.log", package = "EvoPhylo")
posterior <- read.table(posterior, header = TRUE)
plot_treerates_sgn(
type = "BEAST2",
tree_clock1, posterior, #BEAST2 tree file with data for partition 1
trans = "log10",
clock = 1, #Show rates for clock partition 1
threshold = c("1 SD", "3 SD"), #sets background rate threshold for selection mode
branch_size = 1.5, tip_size = 3, #sets size for tree elements
xlim = c(-70, 30), nbreaks = 8, geo_size = list(3, 3)) #sets limits and breaks for geoscale
}Run the code above in your browser using DataLab