Learn R Programming

faunabr (version 1.0.0)

subset_fauna: Extract a subset of species from Fauna do Brasil database

Description

Returns a data.frame with a subset of species from Fauna do Brasil database

Usage

subset_fauna(data, species, include_subspecies = FALSE)

Value

A data.frame with the selected species.

Arguments

data

(data.frame) the data.frame imported with the load_faunabr function.

species

(character) names of the species to be extracted from Fauna do Brasil database.

include_subspecies

(logical) include subspecies? Default = FALSE

Examples

Run this code
data("fauna_data") #Load data example
#Species to extract from database
spp <- c("Panthera onca", "Mazama jucunda", "Subulo gouzoubira")
spp_subset <- subset_fauna(data = fauna_data, species = spp,
                      include_subspecies = FALSE)
spp_subset

Run the code above in your browser using DataLab