Install package
install.packages("rotl")
Load package
library(rotl)
Create and draw phylogeny
Create a list of species
spp <- c("Cenchrus purpureus", "Cenchrus americanus", "Arabidopsis thaliana","Brachypodium distachyon", "Hordeum vulgare","Oryza sativa", "Panicum virgatum","Sorghum bicolor","Setaria italica","Triticum aestivum","Zea mays")
Resolve names
taxa <- tnrs_match_names(spp, context_name = "Flowering plants") # resolve names
Create phylogeny
tr <- tol_induced_subtree(ott_id(taxa), label="name")
Draw phylogeny
plot(tr)