View source: R/function_region_occ.R
get_region_occ | R Documentation |
Auxiliary function to produce an occurrence data frame of species in each region. This object can be
with get_tipranges_to_BioGeoBEARS
function to produce a phyllip file needed in BioGeoBEARS
ancestral area reconstruction
get_region_occ(comm, site.region)
comm |
Occurrence data frame with species in colums and rows corresponding to assemblages |
site.region |
a character vector indicating the membership of each assemblage to regions |
An occurrence data frame with species as rownames and regions as columns
Gabriel Nakamura and Arthur Rodrigues
get_tipranges_to_BioGeoBEARS
data(akodon_sites)
data(akodon_newick)
akodon_pa <- akodon_sites %>% dplyr::select(-LONG, -LAT)
spp_in_tree <- names(akodon_pa) %in% akodon_newick$tip.label
akodon_pa_tree <- akodon_pa[, spp_in_tree]
data(regions)
site_evoregion <- regions$Cluster_Evoregions
get_region_occ(comm=akodon_pa_tree,site.region=site_evoregion)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.