# Generate a set of trees
# data(BirdTree_trees)
# data(BirdTree_tax)
# data(AvotrexPhylo)
# trees <- AvoPhylo(ctrees = BirdTree_trees,
# avotrex = AvotrexPhylo, PER = 0.2, PER_FIXED = 0.75,
# tax = BirdTree_tax, Ntree = 2, n.cores = 2,
# cluster.ips = NULL)
#For here, we can load in an example set of two trees
#generated using the above code
data(treesEx)
#order (owls) - just show extinct tip names (in red) and using
#a fan plot
plot(treesEx[[1]], avotrex = AvotrexPhylo, tax = BirdTree_tax,
order = "Strigiformes", tips = "extinct",
type = "fan", tip.color = "red", cex = 0.4)
#family (plot all three trees this time)
plot(treesEx, avotrex = AvotrexPhylo, tax = BirdTree_tax,
family = "Threskiornithidae", tips = "extinct",
tip.color = "red", cex = 0.5)
#genus - cladogram plot
plot(treesEx[[2]], avotrex = AvotrexPhylo, tax = BirdTree_tax,
genus = "Aplonis", tips = "extinct",
type = "cladogram",
tip.color = "red", cex = 0.5)
#species (& show all tip names in same colour)
species2 <- c("Anas_itchtucknee", "Anas_sp_VitiLevu",
"Anas_platyrhynchos", "Ara_tricolor")
plot(treesEx[[2]], avotrex = AvotrexPhylo, tax = BirdTree_tax,
species = species2, tips = "all_same",
type = "cladogram",
tip.color = "blue", cex = 0.5)
#same as previous, but extinct and extant diff colours
plot(treesEx[[2]], avotrex = AvotrexPhylo, tax = BirdTree_tax,
species = species2,
cex = 0.5, tips = "all_dif",
tips_col = c("red", "darkgreen"),
type = "cladogram")
##single species 2 levels back
plot(treesEx[[2]], avotrex = AvotrexPhylo, tax = BirdTree_tax,
species = "Ara_tricolor",
tips = "all_dif",
tips_col = c("red", "darkgreen"),
lvls = 2,
type = "phylogram",
cex = 0.6)
Run the code above in your browser using DataLab