#Test function
data("fauna_data") #Load fauna e Funga do Brasil data
#Select native species of mammals with occurrence only in Brazil
br_mammals <- select_fauna(data = fauna_data,
include_subspecies = FALSE, phylum = "all",
class = "Mammalia",
order = "all", family = "all",
genus = "all",
lifeForm = "all", filter_lifeForm = "in",
habitat = "all", filter_habitat = "in",
states = "all", filter_states = "in",
country = "BR", filter_country = "only",
origin = "all", taxonomicStatus = "valid")
#Get presence-absence matrix in states
pam_mammals <- fauna_pam(data = br_mammals, by_state = TRUE,
by_country = FALSE,
remove_empty_sites = TRUE,
return_richness_summary = TRUE,
return_spatial_richness = TRUE,
return_plot = TRUE)
Run the code above in your browser using DataLab