Title: | Tools for Accessing the Botanical Information and Ecology Network Database |
---|---|
Description: | Provides Tools for Accessing the Botanical Information and Ecology Network Database. The BIEN database contains cleaned and standardized botanical data including occurrence, trait, plot and taxonomic data (See <https://bien.nceas.ucsb.edu/bien/> for more Information). This package provides functions that query the BIEN database by constructing and executing optimized SQL queries. |
Authors: | Brian Maitner [aut, cre] |
Maintainer: | Brian Maitner <[email protected]> |
License: | MIT + file LICENSE |
Version: | 1.2.7 |
Built: | 2025-01-31 23:38:46 UTC |
Source: | https://github.com/cran/BIEN |
The Botanical Information and Ecology Network(BIEN) R package provides access to the BIEN database as well as useful tools for working with the BIEN data.
Type vignette("BIEN") to view the vignette, which contains useful information on the BIEN package.
Maintainer: Brian Maitner [email protected]
Maitner BS, Boyle B, Casler N, et al. The BIEN R package: A tool to access the Botanical Information and Ecology Network (BIEN) Database. Methods Ecol Evol. 2018;9:373-379. https://doi.org/10.1111/2041-210X.12861
BIEN_list_all produces a list of all species in the BIEN database.
BIEN_list_all(...)
BIEN_list_all(...)
... |
Additional arguments passed to internal functions. |
Dataframe containing a list of all species in the BIEN database.
Other list functions:
BIEN_list_country()
,
BIEN_list_county()
,
BIEN_list_sf()
,
BIEN_list_state()
## Not run: species_list<-BIEN_list_all() ## End(Not run)
## Not run: species_list<-BIEN_list_all() ## End(Not run)
BIEN_list_country downloads a list of all species within a country or countries from the BIEN database.
BIEN_list_country( country = NULL, country.code = NULL, cultivated = FALSE, new.world = NULL, ... )
BIEN_list_country( country = NULL, country.code = NULL, cultivated = FALSE, new.world = NULL, ... )
country |
A single country or a vector of countries. |
country.code |
A single country code or a vector of country codes equal in length to the vector of states/province codes. |
cultivated |
Return information on cultivation status? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
... |
Additional arguments passed to internal functions. |
Dataframe containing species list(s) for the specified country or countries.
Political division (or political division code) spelling needs to be exact and case-sensitive, see BIEN_metadata_list_political_names
for a list of political divisions and associated codes.
Other list functions:
BIEN_list_all()
,
BIEN_list_county()
,
BIEN_list_sf()
,
BIEN_list_state()
## Not run: BIEN_list_country("Canada") country_vector<-c("Canada","United States") BIEN_list_country(country_vector) ## End(Not run)
## Not run: BIEN_list_country("Canada") country_vector<-c("Canada","United States") BIEN_list_country(country_vector) ## End(Not run)
BIEN_list_county produces a list of all species with geovalidated occurrences falling within specified county or counties.
BIEN_list_county( country = NULL, state = NULL, county = NULL, country.code = NULL, state.code = NULL, county.code = NULL, cultivated = FALSE, new.world = NULL, ... )
BIEN_list_county( country = NULL, state = NULL, county = NULL, country.code = NULL, state.code = NULL, county.code = NULL, cultivated = FALSE, new.world = NULL, ... )
country |
A single country or vector of countries |
state |
A state or vector of states (or other primary political divisions, e.g. provinces). |
county |
A single county (or other secondary administrative boundary)or vector of counties. |
country.code |
A single country (or other primary administrative boundary) code or a vector of country codes equal in length to the vector of states/province codes. |
state.code |
A single state/province code, or a vector of states/province codes. |
county.code |
A single county (or other secondary administrative boundary) code or a vector of county codes equal in length to the vectors of states/province codes and country codes. |
cultivated |
Return information on cultivation status? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
... |
Additional arguments passed to internal functions. |
Dataframe containing species list(s) for the specified states/provinces.
Political division (or political division code) spelling needs to be exact and case-sensitive, see BIEN_metadata_list_political_names
for a list of political divisions and associated codes.
We recommend using country, state, and county rather than codes, since county names have not been fully standardized.
This function requires you supply either 1) a single state and country with one or more counties, or 2) vectors of equal length for each political level.
Other list functions:
BIEN_list_all()
,
BIEN_list_country()
,
BIEN_list_sf()
,
BIEN_list_state()
## Not run: BIEN_list_county("United States", "Michigan", "Kent") BIEN_list_county(country = "United States", state = "Michigan", county = "Kent") county_vector<-c("Kent","Kalamazoo") BIEN_list_county(country = "United States", state = "Michigan", county = county_vector) ## End(Not run)
## Not run: BIEN_list_county("United States", "Michigan", "Kent") BIEN_list_county(country = "United States", state = "Michigan", county = "Kent") county_vector<-c("Kent","Kalamazoo") BIEN_list_county(country = "United States", state = "Michigan", county = county_vector) ## End(Not run)
BIEN_list_sf produces a list of all species with occurrence records falling within a user-supplied sf object.
BIEN_list_sf(sf, cultivated = FALSE, new.world = NULL, ...)
BIEN_list_sf(sf, cultivated = FALSE, new.world = NULL, ...)
sf |
An object of class ff. Note that the object must be in WGS84. |
cultivated |
Return information on cultivation status? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
... |
Additional arguments passed to internal functions. |
Dataframe containing a list of all species with occurrences in the supplied sf object.
Other list functions:
BIEN_list_all()
,
BIEN_list_country()
,
BIEN_list_county()
,
BIEN_list_state()
## Not run: library(sf) BIEN_ranges_species("Carnegiea gigantea") # saves ranges to the current working directory sf <- st_read(dsn = ".", layer = "Carnegiea_gigantea") species_list <- BIEN_list_sf(sf = sf) ## End(Not run)
## Not run: library(sf) BIEN_ranges_species("Carnegiea gigantea") # saves ranges to the current working directory sf <- st_read(dsn = ".", layer = "Carnegiea_gigantea") species_list <- BIEN_list_sf(sf = sf) ## End(Not run)
BIEN_list_state produces a list of all species with geovalidated occurrences falling within specified state(s) or province(s).
BIEN_list_state( country = NULL, country.code = NULL, state = NULL, state.code = NULL, cultivated = FALSE, new.world = NULL, ... )
BIEN_list_state( country = NULL, country.code = NULL, state = NULL, state.code = NULL, cultivated = FALSE, new.world = NULL, ... )
country |
A single country or a vector of countries equal in length to the vector of states/provinces. |
country.code |
A single country code or a vector of country codes equal in length to the vector of states/province codes. |
state |
A state or vector of states (or other primary political divisions, e.g. provinces). |
state.code |
A single state/province code, or a vector of states/province codes. |
cultivated |
Return information on cultivation status? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
... |
Additional arguments passed to internal functions. |
Dataframe containing species list(s) for the specified states/provinces.
Political division (or political division code) spelling needs to be exact and case-sensitive, see BIEN_metadata_list_political_names
for a list of political divisions and associated codes.
Other list functions:
BIEN_list_all()
,
BIEN_list_country()
,
BIEN_list_county()
,
BIEN_list_sf()
## Not run: BIEN_list_state("United States","Michigan") state_vector<-c("Michigan","Arizona") BIEN_list_state(country="United States", state= state_vector) ## End(Not run)
## Not run: BIEN_list_state("United States","Michigan") state_vector<-c("Michigan","Arizona") BIEN_list_state(country="United States", state= state_vector) ## End(Not run)
BIEN_metadata_citation guides a user through the proper documentation for data downloaded from the BIEN database.
BIEN_metadata_citation( dataframe = NULL, trait.dataframe = NULL, trait.mean.dataframe = NULL, bibtex_file = NULL, acknowledgement_file = NULL, ... )
BIEN_metadata_citation( dataframe = NULL, trait.dataframe = NULL, trait.mean.dataframe = NULL, bibtex_file = NULL, acknowledgement_file = NULL, ... )
dataframe |
A data.frame of occurrence data downloaded from the BIEN R package. |
trait.dataframe |
A data.frame of trait data downloaded from the BIEN R package. |
trait.mean.dataframe |
A data.frame of species mean trait data from the function BIEN_trait_mean. |
bibtex_file |
Output file for writing bibtex citations. |
acknowledgement_file |
Output file for writing acknowledgements. |
... |
Additional arguments passed to internal functions. |
A list object containing information needed for data attribution. Full information for herbaria is available at http://sweetgum.nybg.org/science/ih/
Other metadata functions:
BIEN_metadata_data_dictionaries()
,
BIEN_metadata_database_version()
,
BIEN_metadata_list_political_names()
,
BIEN_metadata_match_data()
,
BIEN_plot_metadata()
,
BIEN_ranges_list()
## Not run: BIEN_metadata_citation()#If you are referencing the phylogeny or range maps. Xanthium_data<-BIEN_occurrence_species("Xanthium strumarium") citations<-BIEN_metadata_citation(dataframe=Xanthium_data)#If you are referencing occurrence data ## End(Not run)
## Not run: BIEN_metadata_citation()#If you are referencing the phylogeny or range maps. Xanthium_data<-BIEN_occurrence_species("Xanthium strumarium") citations<-BIEN_metadata_citation(dataframe=Xanthium_data)#If you are referencing occurrence data ## End(Not run)
BIEN_metadata_database_version downloads the current version number and release date for the BIEN database.
BIEN_metadata_database_version(...)
BIEN_metadata_database_version(...)
... |
Additional arguments passed to internal functions. |
A data frame containing the current version number and release date for the BIEN database.
Other metadata functions:
BIEN_metadata_citation()
,
BIEN_metadata_data_dictionaries()
,
BIEN_metadata_list_political_names()
,
BIEN_metadata_match_data()
,
BIEN_plot_metadata()
,
BIEN_ranges_list()
## Not run: BIEN_metadata_database_version() ## End(Not run)
## Not run: BIEN_metadata_database_version() ## End(Not run)
BIEN_metadata_list_political_names downloads country, state, and county names and associated codes used by BIEN.
BIEN_metadata_list_political_names(...)
BIEN_metadata_list_political_names(...)
... |
Additional arguments passed to internal functions. |
A dataframe containing political division names and their associated codes.
Political names and codes follow http://www.geonames.org/
Other metadata functions:
BIEN_metadata_citation()
,
BIEN_metadata_data_dictionaries()
,
BIEN_metadata_database_version()
,
BIEN_metadata_match_data()
,
BIEN_plot_metadata()
,
BIEN_ranges_list()
## Not run: BIEN_metadata_list_political_names() ## End(Not run)
## Not run: BIEN_metadata_list_political_names() ## End(Not run)
BIEN_metadata_match_data compares old and new dataframes, and can check whether they are identical or be used to select rows that are unique to the old or new versions.
BIEN_metadata_match_data(old, new, return = "identical")
BIEN_metadata_match_data(old, new, return = "identical")
old |
A dataframe that is to be compared to a (typically) newer dataframe. |
new |
A dataframe that is to be compared to a (typically) older dataframe. |
return |
What information should be returned? Current options are: "identical" (Logical, are the two dataframes identical?), "additions" (numeric, which rows are new?), "deletions" (numeric, which rows are no longer present?), "logical" (logical, which elements of the old dataframe are in the new one?). |
Logical of varying length (depending on choice of "return" parameter)
Since comparisons are done by row (except when using return="identical"), this function may fail to flag additions or deletions if they are exact duplicates of existing rows.
Other metadata functions:
BIEN_metadata_citation()
,
BIEN_metadata_data_dictionaries()
,
BIEN_metadata_database_version()
,
BIEN_metadata_list_political_names()
,
BIEN_plot_metadata()
,
BIEN_ranges_list()
## Not run: new<-BIEN_occurrence_species("Acer nigrum") old<-new[-1:-4,]#simulate having an older dataset by removing four rows BIEN_metadata_match_data(old,new,return="identical") BIEN_metadata_match_data(old,new,return="additions") ## End(Not run)
## Not run: new<-BIEN_occurrence_species("Acer nigrum") old<-new[-1:-4,]#simulate having an older dataset by removing four rows BIEN_metadata_match_data(old,new,return="identical") BIEN_metadata_match_data(old,new,return="additions") ## End(Not run)
BIEN_occurrence_box extracts occurrences records falling within the specific area.
BIEN_occurrence_box( min.lat, max.lat, min.long, max.long, species = NULL, genus = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = TRUE, collection.info = FALSE, ... )
BIEN_occurrence_box( min.lat, max.lat, min.long, max.long, species = NULL, genus = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = TRUE, collection.info = FALSE, ... )
min.lat |
Minimum latitude |
max.lat |
Maximum latitude |
min.long |
Minimum longitude |
max.long |
Maximum longitude |
species |
Optional. A single species or a vector of species. |
genus |
Optional. A single genus or a vector of genera. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
observation.type |
Return information on type of observation (i.e. specimen vs. plot)? The default value is FALSE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing occurrence records for the specified area.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Specifying species and/or genera will limit records returned to that set of taxa.
Other occurrence functions:
BIEN_occurrence_country()
,
BIEN_occurrence_county()
,
BIEN_occurrence_family()
,
BIEN_occurrence_genus()
,
BIEN_occurrence_records_per_species()
,
BIEN_occurrence_sf()
,
BIEN_occurrence_species()
,
BIEN_occurrence_state()
## Not run: output_test<- BIEN_occurrence_box(min.lat = 32,max.lat = 33,min.long = -114,max.long = -113, cultivated = TRUE, new.world = FALSE) ## End(Not run)
## Not run: output_test<- BIEN_occurrence_box(min.lat = 32,max.lat = 33,min.long = -114,max.long = -113, cultivated = TRUE, new.world = FALSE) ## End(Not run)
BIEN_occurrence_country extracts occurrences records for the specified country/countries.
BIEN_occurrence_country( country = NULL, country.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, only.geovalid = TRUE, ... )
BIEN_occurrence_country( country = NULL, country.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, only.geovalid = TRUE, ... )
country |
A single country or a vector of country. |
country.code |
A single country code or a vector of country codes equal in length to the vector of states/province codes. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
observation.type |
Return information on type of observation (i.e. specimen vs. plot)? The default value is FALSE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
only.geovalid |
Should the returned records be limited to those with validated coordinates? Default is TRUE |
... |
Additional arguments passed to internal functions. |
Dataframe containing occurrence records for the specified country.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Political division (or political division code) spelling needs to be exact and case-sensitive, see BIEN_metadata_list_political_names
for a list of political divisions and associated codes.
Other occurrence functions:
BIEN_occurrence_box()
,
BIEN_occurrence_county()
,
BIEN_occurrence_family()
,
BIEN_occurrence_genus()
,
BIEN_occurrence_records_per_species()
,
BIEN_occurrence_sf()
,
BIEN_occurrence_species()
,
BIEN_occurrence_state()
## Not run: BIEN_occurrence_country("Cuba") country_vector<-c("Cuba","Bahamas") BIEN_occurrence_country(country_vector) ## End(Not run)
## Not run: BIEN_occurrence_country("Cuba") country_vector<-c("Cuba","Bahamas") BIEN_occurrence_country(country_vector) ## End(Not run)
BIEN_occurrence_county extracts occurrences records for the specified county or counties.
BIEN_occurrence_county( country = NULL, state = NULL, county = NULL, country.code = NULL, state.code = NULL, county.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, ... )
BIEN_occurrence_county( country = NULL, state = NULL, county = NULL, country.code = NULL, state.code = NULL, county.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, ... )
country |
A single country or vector of countries. |
state |
A state or vector of states (or other primary political divisions, e.g. provinces). |
county |
A single county or a vector of counties (or other secondary political division, e.g. parish). |
country.code |
A single country (or other primary administrative boundary) code or a vector of country codes equal in length to the vector of states/province codes. |
state.code |
A single state/province code, or a vector of states/province codes. |
county.code |
A single county (or other secondary administrative boundary) code or a vector of county codes equal in length to the vectors of states/province codes and country codes. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
observation.type |
Return information on type of observation (i.e. specimen vs. plot)? The default value is FALSE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing occurrence records for the specified states/provinces.
Political division (or political division code) spelling needs to be exact and case-sensitive, see BIEN_metadata_list_political_names
for a list of political divisions and associated codes.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
This function requires you supply either 1) a single country with one or more states, or 2) vectors of equal length for each political level.
Other occurrence functions:
BIEN_occurrence_box()
,
BIEN_occurrence_country()
,
BIEN_occurrence_family()
,
BIEN_occurrence_genus()
,
BIEN_occurrence_records_per_species()
,
BIEN_occurrence_sf()
,
BIEN_occurrence_species()
,
BIEN_occurrence_state()
## Not run: BIEN_occurrence_county("United States","Arizona","Pima") country_vector<-c("United States","United States") state_vector<-c("Arizona","Michigan") county_vector<-c("Pima","Kent") BIEN_occurrence_county(country=country_vector, state = state_vector, county = county_vector) ## End(Not run)
## Not run: BIEN_occurrence_county("United States","Arizona","Pima") country_vector<-c("United States","United States") state_vector<-c("Arizona","Michigan") county_vector<-c("Pima","Kent") BIEN_occurrence_county(country=country_vector, state = state_vector, county = county_vector) ## End(Not run)
BIEN_occurrence_family extracts all occurrences for a given family (or families) from the BIEN database.
BIEN_occurrence_family( family, cultivated = FALSE, new.world = NULL, observation.type = FALSE, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, only.geovalid = TRUE, ... )
BIEN_occurrence_family( family, cultivated = FALSE, new.world = NULL, observation.type = FALSE, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, only.geovalid = TRUE, ... )
family |
A single family or a vector of families. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
observation.type |
Return information on type of observation (i.e. specimen vs. plot)? The default value is FALSE. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
only.geovalid |
Should the returned records be limited to those with validated coordinates? Default is TRUE |
... |
Additional arguments passed to internal functions. |
Dataframe containing occurrence records for the specified family/families.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Other occurrence functions:
BIEN_occurrence_box()
,
BIEN_occurrence_country()
,
BIEN_occurrence_county()
,
BIEN_occurrence_genus()
,
BIEN_occurrence_records_per_species()
,
BIEN_occurrence_sf()
,
BIEN_occurrence_species()
,
BIEN_occurrence_state()
## Not run: BIEN_occurrence_family("Theaceae") family_vector<-c("Theaceae","Ericaceae") BIEN_occurrence_family(family_vector) ## End(Not run)
## Not run: BIEN_occurrence_family("Theaceae") family_vector<-c("Theaceae","Ericaceae") BIEN_occurrence_family(family_vector) ## End(Not run)
BIEN_occurrence_genus downloads occurrence records for specific genus/genera from the BIEN database.
BIEN_occurrence_genus( genus, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, ... )
BIEN_occurrence_genus( genus, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, ... )
genus |
A single genus, or a vector of genera. Genera should be capitalized. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
observation.type |
Return information on type of observation (i.e. specimen vs. plot)? The default value is FALSE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing occurrence records for the specified genera.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Other occurrence functions:
BIEN_occurrence_box()
,
BIEN_occurrence_country()
,
BIEN_occurrence_county()
,
BIEN_occurrence_family()
,
BIEN_occurrence_records_per_species()
,
BIEN_occurrence_sf()
,
BIEN_occurrence_species()
,
BIEN_occurrence_state()
## Not run: BIEN_occurrence_genus("Abutilon") genus_vector<-c("Abutilon","Abronia") BIEN_occurrence_genus(genus_vector) BIEN_occurrence_genus(genus = "Abutilon",cultivated = TRUE,new.world = FALSE) ## End(Not run)
## Not run: BIEN_occurrence_genus("Abutilon") genus_vector<-c("Abutilon","Abronia") BIEN_occurrence_genus(genus_vector) BIEN_occurrence_genus(genus = "Abutilon",cultivated = TRUE,new.world = FALSE) ## End(Not run)
BIEN_occurrence_records_per_species downloads a count of the number of geovalidated occurrence records for each species in the BIEN database.
BIEN_occurrence_records_per_species(species = NULL, ...)
BIEN_occurrence_records_per_species(species = NULL, ...)
species |
A single species, or vector of species. If NULL, the default, it will return counts for all species. |
... |
Additional arguments passed to internal functions. |
A dataframe listing the number of geovalidated occurrence records for each species in the BIEN database.
Other occurrence functions:
BIEN_occurrence_box()
,
BIEN_occurrence_country()
,
BIEN_occurrence_county()
,
BIEN_occurrence_family()
,
BIEN_occurrence_genus()
,
BIEN_occurrence_sf()
,
BIEN_occurrence_species()
,
BIEN_occurrence_state()
## Not run: occurrence_counts<-BIEN_occurrence_records_per_species() ## End(Not run)
## Not run: occurrence_counts<-BIEN_occurrence_records_per_species() ## End(Not run)
BIEN_occurrence_sf downloads occurrence records falling within a user-specified sf polygon
BIEN_occurrence_sf( sf, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, ... )
BIEN_occurrence_sf( sf, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, ... )
sf |
An object of class sf. Note that the projection must be WGS84. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
observation.type |
Return information on type of observation (i.e. specimen vs. plot)? The default value is FALSE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing occurrence records falling within the polygon.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Other occurrence functions:
BIEN_occurrence_box()
,
BIEN_occurrence_country()
,
BIEN_occurrence_county()
,
BIEN_occurrence_family()
,
BIEN_occurrence_genus()
,
BIEN_occurrence_records_per_species()
,
BIEN_occurrence_species()
,
BIEN_occurrence_state()
## Not run: library(sf) # first, we download an example shapefile to use (a species range) BIEN_ranges_species("Carnegiea gigantea")#saves range to the current working directory # load the range map as an sf object sf <- st_read(dsn = ".",layer = "Carnegiea_gigantea") # get the occurrences that occur within the polygon. species_occurrences <- BIEN_occurrence_sf(sf = sf) ## End(Not run)
## Not run: library(sf) # first, we download an example shapefile to use (a species range) BIEN_ranges_species("Carnegiea gigantea")#saves range to the current working directory # load the range map as an sf object sf <- st_read(dsn = ".",layer = "Carnegiea_gigantea") # get the occurrences that occur within the polygon. species_occurrences <- BIEN_occurrence_sf(sf = sf) ## End(Not run)
BIEN_occurrence_species downloads occurrence records for specific species from the BIEN database.
BIEN_occurrence_species( species, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, only.geovalid = TRUE, ... )
BIEN_occurrence_species( species, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, only.geovalid = TRUE, ... )
species |
A single species, or a vector of species. Genus and species should be separated by a space. Genus should be capitalized. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
observation.type |
Return information on type of observation (i.e. specimen vs. plot)? The default value is FALSE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
only.geovalid |
Should the returned records be limited to those with validated coordinates? Default is TRUE |
... |
Additional arguments passed to internal functions. |
Dataframe containing occurrence records for the specified species.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Other occurrence functions:
BIEN_occurrence_box()
,
BIEN_occurrence_country()
,
BIEN_occurrence_county()
,
BIEN_occurrence_family()
,
BIEN_occurrence_genus()
,
BIEN_occurrence_records_per_species()
,
BIEN_occurrence_sf()
,
BIEN_occurrence_state()
## Not run: BIEN_occurrence_species("Abies amabilis") species_vector<-c("Abies amabilis", "Acer nigrum") BIEN_occurrence_species(species_vector) BIEN_occurrence_species(species_vector,all.taxonomy = TRUE) ## End(Not run)
## Not run: BIEN_occurrence_species("Abies amabilis") species_vector<-c("Abies amabilis", "Acer nigrum") BIEN_occurrence_species(species_vector) BIEN_occurrence_species(species_vector,all.taxonomy = TRUE) ## End(Not run)
BIEN_occurrence_state extracts occurrences records for the specified state(s).
BIEN_occurrence_state( country = NULL, state = NULL, country.code = NULL, state.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, ... )
BIEN_occurrence_state( country = NULL, state = NULL, country.code = NULL, state.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, observation.type = FALSE, political.boundaries = FALSE, collection.info = FALSE, ... )
country |
A single country or vector of countries. |
state |
A state or vector of states (or other primary political divisions, e.g. provinces). |
country.code |
A single country (or other primary administrative boundary) code or a vector of country codes equal in length to the vector of states/province codes. |
state.code |
A single state/province code, or a vector of states/province codes. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
observation.type |
Return information on type of observation (i.e. specimen vs. plot)? The default value is FALSE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing occurrence records for the specified states/provinces.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Political division (or political division code) spelling needs to be exact and case-sensitive, see BIEN_metadata_list_political_names
for a list of political divisions and associated codes.
This function requires you supply either 1) a single country with one or more states, or 2) vectors of equal length for each political level.
Other occurrence functions:
BIEN_occurrence_box()
,
BIEN_occurrence_country()
,
BIEN_occurrence_county()
,
BIEN_occurrence_family()
,
BIEN_occurrence_genus()
,
BIEN_occurrence_records_per_species()
,
BIEN_occurrence_sf()
,
BIEN_occurrence_species()
## Not run: BIEN_occurrence_state("United States","Rhode Island") state_vector<-c("Rhode Island","Maryland") BIEN_occurrence_state(country="United States",state=state_vector) ## End(Not run)
## Not run: BIEN_occurrence_state("United States","Rhode Island") state_vector<-c("Rhode Island","Maryland") BIEN_occurrence_state(country="United States",state=state_vector) ## End(Not run)
BIEN_phylogeny_complete downloads a specified number of the BIEN phylogeny replicates.
BIEN_phylogeny_complete(n_phylogenies = 1, seed = NULL, replicates = NULL, ...)
BIEN_phylogeny_complete(n_phylogenies = 1, seed = NULL, replicates = NULL, ...)
n_phylogenies |
The number of phylogenies to download. Should be an integer between 1 and 100. Default is 1. |
seed |
Argument passed to set.seed. Useful for replicating work with random phylogeny sets. |
replicates |
The specific replicated phylogenies to return. Should be a numeric vector of integers between 1 and 100. |
... |
Additional arguments passed to internal functions. |
A phylo or multiphylo object containing the specified phylogenies
Information on the construction of the BIEN phylogenies is available online at https://bien.nceas.ucsb.edu/bien/biendata/bien-2/phylogeny/
Other phylogeny functions:
BIEN_phylogeny_conservative()
,
BIEN_phylogeny_label_nodes()
## Not run: phylos<-BIEN_phylogeny_complete(n_phylogenies = 10,seed = 1) phylos<-BIEN_phylogeny_complete(replicates = c(1,2,99,100)) ## End(Not run)
## Not run: phylos<-BIEN_phylogeny_complete(n_phylogenies = 10,seed = 1) phylos<-BIEN_phylogeny_complete(replicates = c(1,2,99,100)) ## End(Not run)
BIEN_phylogeny_conservative downloads the conservative BIEN phylogeny, which only includes species with molecular data available.
BIEN_phylogeny_conservative(...)
BIEN_phylogeny_conservative(...)
... |
Additional arguments passed to internal functions. |
A phylo object containing the BIEN conservative phylogeny
Information on the construction of the BIEN phylogenies is available online at https://bien.nceas.ucsb.edu/bien/biendata/bien-2/phylogeny/
Other phylogeny functions:
BIEN_phylogeny_complete()
,
BIEN_phylogeny_label_nodes()
## Not run: BIEN_phylo<-BIEN_phylogeny_conservative() ## End(Not run)
## Not run: BIEN_phylo<-BIEN_phylogeny_conservative() ## End(Not run)
BIEN_phylogeny_label_nodes will label the nodes on a phylogeny based on either the BIEN taxonomy or user-supplied taxa.
BIEN_phylogeny_label_nodes( phylogeny, family = TRUE, genus = FALSE, other_taxa = NULL, ... )
BIEN_phylogeny_label_nodes( phylogeny, family = TRUE, genus = FALSE, other_taxa = NULL, ... )
phylogeny |
A single phylogeny. |
family |
Should family-level nodes be labeled? Default is TRUE. |
genus |
Should genus-level nodes be labeled? Default is FALSE. Overwrites family-level nodes where a family contains a single genera. |
other_taxa |
A dataframe containing two columns: 1) the taxa to be labelled; 2) the species associated with each taxon. |
... |
Additional arguments passed to internal functions. |
Input phylogeny with labeled nodes.
Information on the construction of the BIEN phylogenies is available online at https://bien.nceas.ucsb.edu/bien/biendata/bien-2/phylogeny/
Other phylogeny functions:
BIEN_phylogeny_complete()
,
BIEN_phylogeny_conservative()
## Not run: phylogeny<-BIEN_phylogeny_conservative() phylogeny<-drop.tip(phy = phylogeny,tip = 101:length(phylogeny$tip.label)) plot.phylo(x = phylogeny,show.tip.label = FALSE) fam_nodes<-BIEN_phylogeny_label_nodes(phylogeny = phylogeny,family = TRUE) plot.phylo(x = fam_nodes,show.tip.label = FALSE, show.node.label = TRUE) gen_nodes<-BIEN_phylogeny_label_nodes(phylogeny = phylogeny, family = FALSE, genus = TRUE) plot.phylo(x = gen_nodes, show.tip.label = FALSE, show.node.label = TRUE) other_taxa <- as.data.frame(matrix(nrow = 10,ncol = 2)) colnames(other_taxa)<-c("taxon","species") other_taxa$taxon[1:5]<-"A" #Randomly assign a few species to taxon A other_taxa$taxon[6:10]<-"B" #Randomly assign a few species to taxon B tax_nodes <- BIEN_phylogeny_label_nodes(phylogeny = phylogeny, family = FALSE, genus = FALSE, other_taxa = other_taxa) plot.phylo(x = tax_nodes,show.tip.label = FALSE,show.node.label = TRUE) ## End(Not run)
## Not run: phylogeny<-BIEN_phylogeny_conservative() phylogeny<-drop.tip(phy = phylogeny,tip = 101:length(phylogeny$tip.label)) plot.phylo(x = phylogeny,show.tip.label = FALSE) fam_nodes<-BIEN_phylogeny_label_nodes(phylogeny = phylogeny,family = TRUE) plot.phylo(x = fam_nodes,show.tip.label = FALSE, show.node.label = TRUE) gen_nodes<-BIEN_phylogeny_label_nodes(phylogeny = phylogeny, family = FALSE, genus = TRUE) plot.phylo(x = gen_nodes, show.tip.label = FALSE, show.node.label = TRUE) other_taxa <- as.data.frame(matrix(nrow = 10,ncol = 2)) colnames(other_taxa)<-c("taxon","species") other_taxa$taxon[1:5]<-"A" #Randomly assign a few species to taxon A other_taxa$taxon[6:10]<-"B" #Randomly assign a few species to taxon B tax_nodes <- BIEN_phylogeny_label_nodes(phylogeny = phylogeny, family = FALSE, genus = FALSE, other_taxa = other_taxa) plot.phylo(x = tax_nodes,show.tip.label = FALSE,show.node.label = TRUE) ## End(Not run)
BIEN_plot_country downloads all plot data from specified countries.
BIEN_plot_country( country = NULL, country.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_plot_country( country = NULL, country.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
country |
A country or vector of countries. |
country.code |
A single country code or a vector of country codes equal in length to the vector of states/province codes. |
cultivated |
Return cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
A dataframe containing all data from the specified countries.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Political division (or political division code) spelling needs to be exact and case-sensitive, see BIEN_metadata_list_political_names
for a list of political divisions and associated codes.
Other plot functions:
BIEN_plot_dataset()
,
BIEN_plot_datasource()
,
BIEN_plot_list_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_metadata()
,
BIEN_plot_name()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_sf()
,
BIEN_plot_state()
## Not run: BIEN_plot_country("Costa Rica") BIEN_plot_country(c("Costa Rica","Panama")) ## End(Not run)
## Not run: BIEN_plot_country("Costa Rica") BIEN_plot_country(c("Costa Rica","Panama")) ## End(Not run)
BIEN_plot_dataset downloads all plot data for a given dataset or datasets.
BIEN_plot_dataset( dataset, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_plot_dataset( dataset, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
dataset |
A plot dataset or vector of datasets. See BIEN_plot_metadata for more information on plots. |
cultivated |
Return cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
A dataframe containing all data from the specified dataset.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Datasets and related information can be looked up with BIEN_plot_metadata
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_datasource()
,
BIEN_plot_list_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_metadata()
,
BIEN_plot_name()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_sf()
,
BIEN_plot_state()
## Not run: BIEN_plot_dataset("Gentry Transect Dataset") ## End(Not run)
## Not run: BIEN_plot_dataset("Gentry Transect Dataset") ## End(Not run)
BIEN_plot_datasource downloads all plot data from a given datasource.
BIEN_plot_datasource( datasource, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_plot_datasource( datasource, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
datasource |
A datasource. See |
cultivated |
Return cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
A dataframe containing all data from the specified datasource.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_dataset()
,
BIEN_plot_list_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_metadata()
,
BIEN_plot_name()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_sf()
,
BIEN_plot_state()
## Not run: BIEN_plot_datasource("SALVIAS") ## End(Not run)
## Not run: BIEN_plot_datasource("SALVIAS") ## End(Not run)
BIEN_plot_list_datasource list all plot datasources in the BIEN database.
BIEN_plot_list_datasource(...)
BIEN_plot_list_datasource(...)
... |
Additional arguments passed to internal functions. |
A vector of available datasources.
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_dataset()
,
BIEN_plot_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_metadata()
,
BIEN_plot_name()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_sf()
,
BIEN_plot_state()
## Not run: BIEN_plot_list_datasource() ## End(Not run)
## Not run: BIEN_plot_list_datasource() ## End(Not run)
BIEN_plot_list_sampling_protocols list all available sampling protocols.
BIEN_plot_list_sampling_protocols(...)
BIEN_plot_list_sampling_protocols(...)
... |
Additional arguments passed to internal functions. |
A vector of available sampling protocols.
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_dataset()
,
BIEN_plot_datasource()
,
BIEN_plot_list_datasource()
,
BIEN_plot_metadata()
,
BIEN_plot_name()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_sf()
,
BIEN_plot_state()
## Not run: BIEN_plot_list_sampling_protocols() ## End(Not run)
## Not run: BIEN_plot_list_sampling_protocols() ## End(Not run)
BIEN_plot_metadata downloads the plot metadata table.
BIEN_plot_metadata(...)
BIEN_plot_metadata(...)
... |
Additional arguments passed to internal functions. |
A dataframe containing plot metadata.
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_dataset()
,
BIEN_plot_datasource()
,
BIEN_plot_list_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_name()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_sf()
,
BIEN_plot_state()
Other metadata functions:
BIEN_metadata_citation()
,
BIEN_metadata_data_dictionaries()
,
BIEN_metadata_database_version()
,
BIEN_metadata_list_political_names()
,
BIEN_metadata_match_data()
,
BIEN_ranges_list()
## Not run: BIEN_plot_metadata() ## End(Not run)
## Not run: BIEN_plot_metadata() ## End(Not run)
BIEN_plot_name downloads all plot data for a set of plot names.
BIEN_plot_name( plot.name, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_plot_name( plot.name, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
plot.name |
A plot name or vector of names. See BIEN_plot_metadata for more information on plots. |
cultivated |
Return cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
A dataframe containing all data from the specified plot(s).
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Plot names can be looked up with BIEN_plot_metadata
.
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_dataset()
,
BIEN_plot_datasource()
,
BIEN_plot_list_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_metadata()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_sf()
,
BIEN_plot_state()
## Not run: BIEN_plot_name("SR-1") ## End(Not run)
## Not run: BIEN_plot_name("SR-1") ## End(Not run)
BIEN_plot_sampling_protocol downloads all plot data using a specified sampling protocol.
BIEN_plot_sampling_protocol( sampling_protocol, cultivated = FALSE, new.world = FALSE, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_plot_sampling_protocol( sampling_protocol, cultivated = FALSE, new.world = FALSE, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
sampling_protocol |
A sampling protocol or vector of sampling protocols. See |
cultivated |
Return cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
A dataframe containing all data from the specified datasource.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_dataset()
,
BIEN_plot_datasource()
,
BIEN_plot_list_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_metadata()
,
BIEN_plot_name()
,
BIEN_plot_sf()
,
BIEN_plot_state()
## Not run: BIEN_plot_sampling_protocol("Point-intercept") ## End(Not run)
## Not run: BIEN_plot_sampling_protocol("Point-intercept") ## End(Not run)
BIEN_plot_sf downloads all plot data falling within a supplied sf polygon.
BIEN_plot_sf( sf, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = TRUE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_plot_sf( sf, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = TRUE, collection.info = FALSE, all.metadata = FALSE, ... )
sf |
An object of class sf. Note that the projection must be WGS84. |
cultivated |
Return cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
A dataframe containing all plot data from within the specified sf polygon.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_dataset()
,
BIEN_plot_datasource()
,
BIEN_plot_list_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_metadata()
,
BIEN_plot_name()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_state()
## Not run: library(sf) BIEN_ranges_species("Carnegiea gigantea") #saves ranges to the current working directory sf <- st_read(dsn = ".", layer = "Carnegiea_gigantea") saguaro_plot_data <- BIEN_plot_sf(sf = sf) ## End(Not run)
## Not run: library(sf) BIEN_ranges_species("Carnegiea gigantea") #saves ranges to the current working directory sf <- st_read(dsn = ".", layer = "Carnegiea_gigantea") saguaro_plot_data <- BIEN_plot_sf(sf = sf) ## End(Not run)
BIEN_plot_state downloads all plot data from specified states/provinces.
BIEN_plot_state( country = NULL, state = NULL, country.code = NULL, state.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = TRUE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_plot_state( country = NULL, state = NULL, country.code = NULL, state.code = NULL, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = TRUE, collection.info = FALSE, all.metadata = FALSE, ... )
country |
A single country. |
state |
A state or vector of states (or other primary political divisions). |
country.code |
A single country code or a vector of country codes equal in length to the vector of states/province codes. |
state.code |
A single state/province code, or a vector of states/province codes. |
cultivated |
Return cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
A dataframe containing all data from the specified states.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Political division (or political division code) spelling needs to be exact and case-sensitive, see BIEN_metadata_list_political_names
for a list of political divisions and associated codes.
This function requires you supply either 1) a single country with one or states, or 2) vectors of equal length for each political level.
Other plot functions:
BIEN_plot_country()
,
BIEN_plot_dataset()
,
BIEN_plot_datasource()
,
BIEN_plot_list_datasource()
,
BIEN_plot_list_sampling_protocols()
,
BIEN_plot_metadata()
,
BIEN_plot_name()
,
BIEN_plot_sampling_protocol()
,
BIEN_plot_sf()
## Not run: BIEN_plot_state(country="United States", state="Colorado") BIEN_plot_state(country="United States",state= c("Colorado","California")) ## End(Not run)
## Not run: BIEN_plot_state(country="United States", state="Colorado") BIEN_plot_state(country="United States",state= c("Colorado","California")) ## End(Not run)
BIEN_ranges_box extracts range maps for a specified bounding box.
BIEN_ranges_box( min.lat, max.lat, min.long, max.long, directory = NULL, species.names.only = FALSE, return.species.list = TRUE, crop.ranges = FALSE, include.gid = FALSE, ... )
BIEN_ranges_box( min.lat, max.lat, min.long, max.long, directory = NULL, species.names.only = FALSE, return.species.list = TRUE, crop.ranges = FALSE, include.gid = FALSE, ... )
min.lat |
Minimum latitude of the ranges included. |
max.lat |
Maximum latitude of the ranges included. |
min.long |
Minimum longitude of the ranges included. |
max.long |
Maximum longitude of the ranges included. |
directory |
Directory that range maps should be saved in. If none is specified, range maps will be saved in the current working directory. |
species.names.only |
Return species names rather than spatial data? Default is FALSE. |
return.species.list |
Should a species list be returned in addition to downloading range maps? Default is FALSE |
crop.ranges |
Should the ranges be cropped to the focal area? Default is FALSE. |
include.gid |
Should the files returned have a unique GID appended to them? This is needed if downloading multiple maps for the same species. |
... |
Additional arguments passed to internal functions. |
Range maps for all available species within the specified bounding box.
Details on the construction of BIEN range maps is available at https://bien.nceas.ucsb.edu/bien/biendata/bien-3/
Other range functions:
BIEN_ranges_genus()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_list()
,
BIEN_ranges_load_species()
,
BIEN_ranges_sf()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species()
,
BIEN_ranges_species_bulk()
## Not run: temp_dir <- file.path(tempdir(), "BIEN_temp") #Set a working directory BIEN_ranges_box(42,43,-85,-84,species.names.only = TRUE) BIEN_ranges_box(42,43,-85,-84,directory = temp_dir) ## End(Not run)
## Not run: temp_dir <- file.path(tempdir(), "BIEN_temp") #Set a working directory BIEN_ranges_box(42,43,-85,-84,species.names.only = TRUE) BIEN_ranges_box(42,43,-85,-84,directory = temp_dir) ## End(Not run)
BIEN_ranges_genus extracts range maps for the specified genera.
BIEN_ranges_genus( genus, directory = NULL, matched = TRUE, match_names_only = FALSE, include.gid = FALSE, ... )
BIEN_ranges_genus( genus, directory = NULL, matched = TRUE, match_names_only = FALSE, include.gid = FALSE, ... )
genus |
A single genus or a vector of genera. |
directory |
Directory that range maps should be saved in. If none is specified, range maps will be saved in the current working directory. |
matched |
Return a list of taxa that were downloaded. Default is TRUE. |
match_names_only |
Check for range maps for the taxa specified without downloading range maps. Default is FALSE. |
include.gid |
Should the files returned have a unique GID appended to them? This is needed if downloading multiple maps for the same species. |
... |
Additional arguments passed to internal functions. |
Range maps for all available species within the specified genera.
Details on the construction of BIEN range maps is available at https://bien.nceas.ucsb.edu/bien/biendata/bien-3/
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_list()
,
BIEN_ranges_load_species()
,
BIEN_ranges_sf()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species()
,
BIEN_ranges_species_bulk()
## Not run: library(maps) library(sf) genus_vector <- c("Abies","Acer") temp_dir <- file.path(tempdir(), "BIEN_temp")#Set a working directory BIEN_ranges_genus(genus_vector) BIEN_ranges_genus(genus = genus_vector, match_names_only = TRUE) BIEN_ranges_genus(genus = genus_vector, directory = temp_dir) #saves ranges to a specified working directory BIEN_ranges_genus("Abies") BIEN_ranges_genus(genus = "Abies", directory = temp_dir) #Reading files Abies_poly <- read_sf(dsn = temp_dir,layer = "Abies_lasiocarpa") #Plotting files plot(Abies_poly[1]) #plots the range, but doesn't mean much without any reference map('world', fill = TRUE, col = "grey") #plots a world map (WGS84 projection), in grey plot(Abies_poly[1], col="forest green", add = TRUE) #adds the range of Abies lasiocarpa to the map # Getting data from the files (currently only species names) Abies_poly$species#gives the species name associated with "Abies_poly" ## End(Not run)
## Not run: library(maps) library(sf) genus_vector <- c("Abies","Acer") temp_dir <- file.path(tempdir(), "BIEN_temp")#Set a working directory BIEN_ranges_genus(genus_vector) BIEN_ranges_genus(genus = genus_vector, match_names_only = TRUE) BIEN_ranges_genus(genus = genus_vector, directory = temp_dir) #saves ranges to a specified working directory BIEN_ranges_genus("Abies") BIEN_ranges_genus(genus = "Abies", directory = temp_dir) #Reading files Abies_poly <- read_sf(dsn = temp_dir,layer = "Abies_lasiocarpa") #Plotting files plot(Abies_poly[1]) #plots the range, but doesn't mean much without any reference map('world', fill = TRUE, col = "grey") #plots a world map (WGS84 projection), in grey plot(Abies_poly[1], col="forest green", add = TRUE) #adds the range of Abies lasiocarpa to the map # Getting data from the files (currently only species names) Abies_poly$species#gives the species name associated with "Abies_poly" ## End(Not run)
BIEN_ranges_intersect_species extracts range maps for a specified bounding box.
BIEN_ranges_intersect_species( species, directory = NULL, species.names.only = FALSE, include.focal = TRUE, return.species.list = TRUE, include.gid = FALSE, ... )
BIEN_ranges_intersect_species( species, directory = NULL, species.names.only = FALSE, include.focal = TRUE, return.species.list = TRUE, include.gid = FALSE, ... )
species |
Focal species (or a vector of species) for which to extract intersecting ranges. |
directory |
Directory that range maps should be saved in. If none is specified, range maps will be saved in the current working directory. |
species.names.only |
Return species names rather than spatial data? Default is FALSE. |
include.focal |
Should a range for the focal species be downloaded? Default is TRUE. |
return.species.list |
Should a species list be returned in addition to downloading range maps? Default is FALSE |
include.gid |
Should the files returned have a unique GID appended to them? This is needed if downloading multiple maps for the same species. |
... |
Additional arguments passed to internal functions. |
Range maps for all available species that intersect the range of the focal species.
Details on the construction of BIEN range maps is available at https://bien.nceas.ucsb.edu/bien/biendata/bien-3/
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_genus()
,
BIEN_ranges_list()
,
BIEN_ranges_load_species()
,
BIEN_ranges_sf()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species()
,
BIEN_ranges_species_bulk()
## Not run: temp_dir <- file.path(tempdir(), "BIEN_temp") #Set a working directory BIEN_ranges_intersect_species(species = "Carnegiea_gigantea", directory = temp_dir,include.focal = TRUE) species_vector<-c("Carnegiea_gigantea","Echinocereus coccineus") BIEN_ranges_intersect_species(species = species_vector,species.names.only = TRUE) ## End(Not run)
## Not run: temp_dir <- file.path(tempdir(), "BIEN_temp") #Set a working directory BIEN_ranges_intersect_species(species = "Carnegiea_gigantea", directory = temp_dir,include.focal = TRUE) species_vector<-c("Carnegiea_gigantea","Echinocereus coccineus") BIEN_ranges_intersect_species(species = species_vector,species.names.only = TRUE) ## End(Not run)
BIEN_ranges_list a data.frame containing listing all range maps currently available.
BIEN_ranges_list(...)
BIEN_ranges_list(...)
... |
Additional arguments passed to internal functions. |
A data.frame containing the available species and their associated GIDs.
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_genus()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_load_species()
,
BIEN_ranges_sf()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species()
,
BIEN_ranges_species_bulk()
Other metadata functions:
BIEN_metadata_citation()
,
BIEN_metadata_data_dictionaries()
,
BIEN_metadata_database_version()
,
BIEN_metadata_list_political_names()
,
BIEN_metadata_match_data()
,
BIEN_plot_metadata()
## Not run: available_maps<-BIEN_ranges_list() ## End(Not run)
## Not run: available_maps<-BIEN_ranges_list() ## End(Not run)
BIEN_ranges_load_species returns spatial data for the specified species.
BIEN_ranges_load_species(species, ...)
BIEN_ranges_load_species(species, ...)
species |
A single species or a vector of species. |
... |
Additional arguments passed to internal functions. |
A sf containing range maps for the specified species.
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_genus()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_list()
,
BIEN_ranges_sf()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species()
,
BIEN_ranges_species_bulk()
## Not run: library(maps) species_vector<-c("Abies_lasiocarpa","Abies_amabilis") abies_maps <- BIEN_ranges_load_species(species = species_vector) xanthium_strumarium <- BIEN_ranges_load_species(species = "Xanthium strumarium") #Plotting files plot(abies_maps) # plots the sf, but doesn't mean much without any reference map('world', fill = TRUE, col = "grey")#plots a world map (WGS84 projection), in grey plot(xanthium_strumarium,col="forest green",add = TRUE) #adds the range of X. strumarium plot(abies_maps[1,], add = TRUE, col ="light green") ## End(Not run)
## Not run: library(maps) species_vector<-c("Abies_lasiocarpa","Abies_amabilis") abies_maps <- BIEN_ranges_load_species(species = species_vector) xanthium_strumarium <- BIEN_ranges_load_species(species = "Xanthium strumarium") #Plotting files plot(abies_maps) # plots the sf, but doesn't mean much without any reference map('world', fill = TRUE, col = "grey")#plots a world map (WGS84 projection), in grey plot(xanthium_strumarium,col="forest green",add = TRUE) #adds the range of X. strumarium plot(abies_maps[1,], add = TRUE, col ="light green") ## End(Not run)
BIEN_ranges_sf extracts range maps that intersect a specified simple features (sf) object.
BIEN_ranges_sf( sf, directory = NULL, species.names.only = FALSE, return.species.list = TRUE, crop.ranges = FALSE, include.gid = FALSE, ... )
BIEN_ranges_sf( sf, directory = NULL, species.names.only = FALSE, return.species.list = TRUE, crop.ranges = FALSE, include.gid = FALSE, ... )
sf |
An object of class sf. |
directory |
Directory that range maps should be saved in. If none is specified, range maps will be saved in the current working directory. |
species.names.only |
Return species names rather than spatial data? Default is FALSE. |
return.species.list |
Should a species list be returned in addition to downloading range maps? Default is FALSE |
crop.ranges |
Should the ranges be cropped to the focal area? Default is FALSE. |
include.gid |
Should the files returned have a unique GID appended to them? This is needed if downloading multiple maps for the same species. |
... |
Additional arguments passed to internal functions. |
All range maps that intersect the user-supplied sf object.
Details on the construction of BIEN range maps is available at https://bien.nceas.ucsb.edu/bien/biendata/bien-3/
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_genus()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_list()
,
BIEN_ranges_load_species()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species()
,
BIEN_ranges_species_bulk()
## Not run: # Here we use a range map as our example polygon BIEN_ranges_species("Carnegiea gigantea") #saves ranges to the current working directory # Read in the polygon with sf sf <- sf::st_read(dsn = ".", layer = "Carnegiea_gigantea") BIEN_ranges_sf(sf = sf, limit = 10) # We use the limit argument to return only 10 range maps. # Omit the limit argument to get all ranges #Note that this will save many shapefiles to the working directory. ## End(Not run)
## Not run: # Here we use a range map as our example polygon BIEN_ranges_species("Carnegiea gigantea") #saves ranges to the current working directory # Read in the polygon with sf sf <- sf::st_read(dsn = ".", layer = "Carnegiea_gigantea") BIEN_ranges_sf(sf = sf, limit = 10) # We use the limit argument to return only 10 range maps. # Omit the limit argument to get all ranges #Note that this will save many shapefiles to the working directory. ## End(Not run)
BIEN_ranges_shapefile_to_skinny converts ranges to a "skinny" format to save space.
BIEN_ranges_shapefile_to_skinny(directory, raster, skinny_ranges_file = NULL)
BIEN_ranges_shapefile_to_skinny(directory, raster, skinny_ranges_file = NULL)
directory |
The directory where range shapefiles will be stored. If NULL, a temporary directory will be used. |
raster |
A raster (which must have a CRS specified) to be used for rasterizing the ranges. |
skinny_ranges_file |
A filename that will be used to write the skinny ranges will be written to (RDS format). If NULL, this will not be written. |
Matrix containing 2 columns: 1) Species name; and 2) the raster cell number it occurs within.
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_genus()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_list()
,
BIEN_ranges_load_species()
,
BIEN_ranges_sf()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species()
,
BIEN_ranges_species_bulk()
## Not run: BIEN_ranges_shapefile_to_skinny(directory = BIEN_ranges_species_bulk(species = c("Acer rubrum")), raster = terra::rast(crs = "+proj=laea +lat_0=15 +lon_0=-80 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs +ellps=WGS84 +towgs84=0,0,0", extent = terra::ext(c(-5261554,5038446,-7434988,7165012 )), resolution =c(100000,100000) ) ) ## End(Not run)
## Not run: BIEN_ranges_shapefile_to_skinny(directory = BIEN_ranges_species_bulk(species = c("Acer rubrum")), raster = terra::rast(crs = "+proj=laea +lat_0=15 +lon_0=-80 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs +ellps=WGS84 +towgs84=0,0,0", extent = terra::ext(c(-5261554,5038446,-7434988,7165012 )), resolution =c(100000,100000) ) ) ## End(Not run)
BIEN_ranges_skinny_ranges_to_richness_raster takes in "skinny" range data and converts it to a richness raster.
BIEN_ranges_skinny_ranges_to_richness_raster(skinny_ranges, raster)
BIEN_ranges_skinny_ranges_to_richness_raster(skinny_ranges, raster)
skinny_ranges |
A matrix output by the function "BIEN_ranges_skinny" or equivalent methods. |
raster |
The raster that was used in building the skinny_ranges matrix. |
Raster
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_genus()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_list()
,
BIEN_ranges_load_species()
,
BIEN_ranges_sf()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_species()
,
BIEN_ranges_species_bulk()
## Not run: template_raster <- terra::rast( crs = "+proj=laea +lat_0=15 +lon_0=-80 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs +ellps=WGS84 +towgs84=0,0,0", ext = ext(c(-5261554, 5038446, -7434988, 7165012 )), resolution = c(100000, 100000)) #Download ranges and convert to a "skinny" format skinny_ranges <- BIEN_ranges_shapefile_to_skinny( directory = BIEN_ranges_species_bulk(species = c("Acer rubrum"), raster = template_raster) #Convert from skinny format to richness raster richness_raster<- BIEN_ranges_skinny_ranges_to_richness_raster( skinny_ranges = skinny_ranges,raster = template_raster) plot(richness_raster) ## End(Not run)
## Not run: template_raster <- terra::rast( crs = "+proj=laea +lat_0=15 +lon_0=-80 +x_0=0 +y_0=0 +datum=WGS84 +units=m +no_defs +ellps=WGS84 +towgs84=0,0,0", ext = ext(c(-5261554, 5038446, -7434988, 7165012 )), resolution = c(100000, 100000)) #Download ranges and convert to a "skinny" format skinny_ranges <- BIEN_ranges_shapefile_to_skinny( directory = BIEN_ranges_species_bulk(species = c("Acer rubrum"), raster = template_raster) #Convert from skinny format to richness raster richness_raster<- BIEN_ranges_skinny_ranges_to_richness_raster( skinny_ranges = skinny_ranges,raster = template_raster) plot(richness_raster) ## End(Not run)
BIEN_ranges_species extracts range maps for the specified species.
BIEN_ranges_species( species, directory = NULL, matched = TRUE, match_names_only = FALSE, include.gid = FALSE, ... )
BIEN_ranges_species( species, directory = NULL, matched = TRUE, match_names_only = FALSE, include.gid = FALSE, ... )
species |
A single species or a vector of species. |
directory |
Directory that range maps should be saved in. If none is specified, range maps will be saved in the current working directory. |
matched |
Return a list of taxa that were downloaded. Default is TRUE. |
match_names_only |
Check for range maps for the taxa specified without downloading range maps. Default is FALSE. |
include.gid |
Should the files returned have a unique GID appended to them? This is needed if downloading multiple maps for the same species. |
... |
Additional arguments passed to internal functions. |
Range maps for specified species.
Details on the construction of BIEN range maps is available at https://bien.nceas.ucsb.edu/bien/biendata/bien-3/
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_genus()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_list()
,
BIEN_ranges_load_species()
,
BIEN_ranges_sf()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species_bulk()
## Not run: library(sf) library(maps) #a convenient source of maps species_vector <- c("Abies_lasiocarpa","Abies_amabilis") BIEN_ranges_species(species_vector) BIEN_ranges_species(species_vector, match_names_only = TRUE) temp_dir <- file.path(tempdir(), "BIEN_temp")#Set a working directory BIEN_ranges_species(species = species_vector, directory = temp_dir)#saves ranges to a temporary directory BIEN_ranges_species("Abies_lasiocarpa") BIEN_ranges_species("Abies_lasiocarpa", directory = temp_dir) #Reading files Abies_poly <- st_read(dsn = temp_dir, layer = "Abies_lasiocarpa") #Plotting files plot(Abies_poly[1])#plots the range, but doesn't mean much without any reference map('world', fill = TRUE, col = "grey")#plots a world map (WGS84 projection), in grey plot(Abies_poly[1], col = "forest green", add = TRUE) #adds the range of Abies lasiocarpa to the map # Getting data from the files (currently only species names and a BIEN ID field) Abies_poly$species#gives the species name associated with "Abies_poly" ## End(Not run)#'
## Not run: library(sf) library(maps) #a convenient source of maps species_vector <- c("Abies_lasiocarpa","Abies_amabilis") BIEN_ranges_species(species_vector) BIEN_ranges_species(species_vector, match_names_only = TRUE) temp_dir <- file.path(tempdir(), "BIEN_temp")#Set a working directory BIEN_ranges_species(species = species_vector, directory = temp_dir)#saves ranges to a temporary directory BIEN_ranges_species("Abies_lasiocarpa") BIEN_ranges_species("Abies_lasiocarpa", directory = temp_dir) #Reading files Abies_poly <- st_read(dsn = temp_dir, layer = "Abies_lasiocarpa") #Plotting files plot(Abies_poly[1])#plots the range, but doesn't mean much without any reference map('world', fill = TRUE, col = "grey")#plots a world map (WGS84 projection), in grey plot(Abies_poly[1], col = "forest green", add = TRUE) #adds the range of Abies lasiocarpa to the map # Getting data from the files (currently only species names and a BIEN ID field) Abies_poly$species#gives the species name associated with "Abies_poly" ## End(Not run)#'
BIEN_ranges_species_bulk downloads ranges for a large number of species using parallel processing.
BIEN_ranges_species_bulk( species = NULL, directory = NULL, batch_size = 1000, return_directory = TRUE, use_parallel = FALSE )
BIEN_ranges_species_bulk( species = NULL, directory = NULL, batch_size = 1000, return_directory = TRUE, use_parallel = FALSE )
species |
A vector of species or NULL (the default). If NULL, all available ranges will be used. |
directory |
The directory where range shapefiles will be stored. If NULL, a temporary directory will be used. |
batch_size |
The number of ranges to download at once. |
return_directory |
Should the directory be returned? Default is TRUE |
use_parallel |
Logical. Should batches be downloaded in parallel? If set to TRUE, AND if parallel and foreach are available, parallel processing of downloads will use n-1 clusters. |
Optionally, the directory to which the files were saved.
This function may take a long time (hours) to run depending on the number of cores, download speed, etc.
Other range functions:
BIEN_ranges_box()
,
BIEN_ranges_genus()
,
BIEN_ranges_intersect_species()
,
BIEN_ranges_list()
,
BIEN_ranges_load_species()
,
BIEN_ranges_sf()
,
BIEN_ranges_shapefile_to_skinny()
,
BIEN_ranges_skinny_ranges_to_richness_raster()
,
BIEN_ranges_species()
## Not run: #To download all BIEN ranges maps: BIEN_ranges_species_bulk() ## End(Not run)
## Not run: #To download all BIEN ranges maps: BIEN_ranges_species_bulk() ## End(Not run)
BIEN_stem_datasource downloads occurrence records for specific datasources from the BIEN database.
BIEN_stem_datasource( datasource, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_stem_datasource( datasource, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
datasource |
A single datasource, or a vector of datasources. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing stem data for the specified datasource.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Setting either "cultivated" or "native.status" to TRUE will significantly slow the speed of a query.
#' @note For a list of available datasources, use BIEN_plot_list_datasource
.
Other stem functions:
BIEN_stem_family()
,
BIEN_stem_genus()
,
BIEN_stem_sampling_protocol()
,
BIEN_stem_species()
## Not run: BIEN_stem_datasource(datasource = "SALVIAS") ## End(Not run)
## Not run: BIEN_stem_datasource(datasource = "SALVIAS") ## End(Not run)
BIEN_stem_family downloads occurrence records for specific families from the BIEN database.
BIEN_stem_family( family, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_stem_family( family, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
family |
A single family, or a vector of families. Families should be capitalized. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing stem data for the specified families.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Setting either "cultivated" or "native.status" to TRUE will significantly slow the speed of a query.
Other stem functions:
BIEN_stem_datasource()
,
BIEN_stem_genus()
,
BIEN_stem_sampling_protocol()
,
BIEN_stem_species()
## Not run: BIEN_stem_family(family = "Marantaceae") family_vector<-c("Marantaceae", "Buxaceae") BIEN_stem_family(family = family_vector) BIEN_stem_family(family = family_vector, all.taxonomy = TRUE, native.status = TRUE) ## End(Not run)
## Not run: BIEN_stem_family(family = "Marantaceae") family_vector<-c("Marantaceae", "Buxaceae") BIEN_stem_family(family = family_vector) BIEN_stem_family(family = family_vector, all.taxonomy = TRUE, native.status = TRUE) ## End(Not run)
BIEN_stem_genus downloads occurrence records for specific genera from the BIEN database.
BIEN_stem_genus( genus, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_stem_genus( genus, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
genus |
A single genus, or a vector of genera. Genera should be capitalized. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing stem data for the specified genera.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Setting either "cultivated" or "native.status" to TRUE will significantly slow the speed of a query.
Other stem functions:
BIEN_stem_datasource()
,
BIEN_stem_family()
,
BIEN_stem_sampling_protocol()
,
BIEN_stem_species()
## Not run: BIEN_stem_genus(genus = "Tovomita") genus_vector<-c("Tovomita", "Myrcia") BIEN_stem_genus(genus = genus_vector) BIEN_stem_genus(genus = genus_vector, all.taxonomy = TRUE) ## End(Not run)
## Not run: BIEN_stem_genus(genus = "Tovomita") genus_vector<-c("Tovomita", "Myrcia") BIEN_stem_genus(genus = genus_vector) BIEN_stem_genus(genus = genus_vector, all.taxonomy = TRUE) ## End(Not run)
BIEN_stem_sampling_protocol downloads plot-based stem data using a specified sampling protocol.
BIEN_stem_sampling_protocol( sampling_protocol, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_stem_sampling_protocol( sampling_protocol, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
sampling_protocol |
A sampling protocol or vector of sampling protocols. See |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
A dataframe containing all data from the specified sampling protocol.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Other stem functions:
BIEN_stem_datasource()
,
BIEN_stem_family()
,
BIEN_stem_genus()
,
BIEN_stem_species()
## Not run: BIEN_stem_sampling_protocol("Point-intercept") ## End(Not run)
## Not run: BIEN_stem_sampling_protocol("Point-intercept") ## End(Not run)
BIEN_stem_species downloads occurrence records for specific species from the BIEN database.
BIEN_stem_species( species, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
BIEN_stem_species( species, cultivated = FALSE, new.world = NULL, all.taxonomy = FALSE, native.status = FALSE, natives.only = TRUE, political.boundaries = FALSE, collection.info = FALSE, all.metadata = FALSE, ... )
species |
A single species, or a vector of species. Genus and species should be separated by a space. Genus should be capitalized. |
cultivated |
Return known cultivated records as well? Default is FALSE. |
new.world |
NULL (The default) returns global records, TRUE returns only New World, and FALSE only Old World. |
all.taxonomy |
Return all taxonomic information? This includes the raw data as well as the "scrubbed" data. |
native.status |
Return information on introduction status? The default value is FALSE. A value of TRUE also returns additional information on introduction status. |
natives.only |
Exclude detected introduced species? Default is TRUE. |
political.boundaries |
Return information on political boundaries for an observation? The default value is FALSE. |
collection.info |
Return additional information about collection and identification? The default value is FALSE. |
all.metadata |
Should additional plot metadata be returned? Default is FALSE. |
... |
Additional arguments passed to internal functions. |
Dataframe containing stem data for the specified species.
US FIA coordinates have been fuzzed and swapped, for more details see: https://www.fia.fs.fed.us/tools-data/spatial/Policy/index.php
Setting either "cultivated" or "native.status" to TRUE will significantly slow the speed of a query.
Other stem functions:
BIEN_stem_datasource()
,
BIEN_stem_family()
,
BIEN_stem_genus()
,
BIEN_stem_sampling_protocol()
## Not run: BIEN_stem_species("Abies amabilis") species_vector<-c("Abies amabilis", "Acer nigrum") BIEN_stem_species(species_vector) BIEN_stem_species(species_vector,all.taxonomy = TRUE) ## End(Not run)
## Not run: BIEN_stem_species("Abies amabilis") species_vector<-c("Abies amabilis", "Acer nigrum") BIEN_stem_species(species_vector) BIEN_stem_species(species_vector,all.taxonomy = TRUE) ## End(Not run)
BIEN_taxonomy_family downloads a dataframe of all taxonomic information for given families.
BIEN_taxonomy_family(family, ...)
BIEN_taxonomy_family(family, ...)
family |
A single family or a vector of families. |
... |
Additional arguments passed to internal functions. |
Dataframe containing taxonomic information for the specified families.
Other taxonomy functions:
BIEN_taxonomy_genus()
,
BIEN_taxonomy_species()
## Not run: BIEN_taxonomy_family("Orchidaceae") family_vector<-c("Orchidaceae","Poaceae") BIEN_taxonomy_family(family_vector) ## End(Not run)
## Not run: BIEN_taxonomy_family("Orchidaceae") family_vector<-c("Orchidaceae","Poaceae") BIEN_taxonomy_family(family_vector) ## End(Not run)
BIEN_taxonomy_genus downloads a dataframe of all taxonomic information for given genera.
BIEN_taxonomy_genus(genus, ...)
BIEN_taxonomy_genus(genus, ...)
genus |
A single genus or a vector of genera. |
... |
Additional arguments passed to internal functions. |
Dataframe containing taxonomic information for the specified genera.
Other taxonomy functions:
BIEN_taxonomy_family()
,
BIEN_taxonomy_species()
## Not run: BIEN_taxonomy_genus("Acer") genus_vector<-c("Acer","Quercus") BIEN_taxonomy_genus(genus_vector) ## End(Not run)
## Not run: BIEN_taxonomy_genus("Acer") genus_vector<-c("Acer","Quercus") BIEN_taxonomy_genus(genus_vector) ## End(Not run)
BIEN_taxonomy_species downloads a dataframe of all taxonomic information for given species.
BIEN_taxonomy_species(species, ...)
BIEN_taxonomy_species(species, ...)
species |
A single species or a vector of species. |
... |
Additional arguments passed to internal functions. |
Dataframe containing taxonomic information for the specified species.
Other taxonomy functions:
BIEN_taxonomy_family()
,
BIEN_taxonomy_genus()
## Not run: BIEN_taxonomy_species("Cannabis sativa") species_vector<-c("Acer nigrum","Cannabis sativa") BIEN_taxonomy_species(species_vector) ## End(Not run)
## Not run: BIEN_taxonomy_species("Cannabis sativa") species_vector<-c("Acer nigrum","Cannabis sativa") BIEN_taxonomy_species(species_vector) ## End(Not run)
BIEN_trait_species extracts trait data for the species country.
BIEN_trait_country( country, trait.name = NULL, all.taxonomy = FALSE, political.boundaries = TRUE, source.citation = FALSE, ... )
BIEN_trait_country( country, trait.name = NULL, all.taxonomy = FALSE, political.boundaries = TRUE, source.citation = FALSE, ... )
country |
A single country or a vector of countries. |
trait.name |
Optional. The trait or traits you want returned. If left blank, all traits will be returned. |
all.taxonomy |
Should full taxonomic information and TNRS output be returned? Default is FALSE. |
political.boundaries |
Should political boundary information (country, state, etc.) be returned? Default is FALSE. |
source.citation |
Should readable source information be downloaded for each record? Note that |
... |
Additional arguments passed to internal functions. |
A dataframe of all available trait data for the given country.
Other trait functions:
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_country("South Africa") BIEN_trait_country(country="South Africa",trait="whole plant growth form") ## End(Not run)
## Not run: BIEN_trait_country("South Africa") BIEN_trait_country(country="South Africa",trait="whole plant growth form") ## End(Not run)
BIEN_trait_family extracts all trait data for the specified families.
BIEN_trait_family( family, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
BIEN_trait_family( family, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
family |
A single family or a vector of families. |
all.taxonomy |
Should full taxonomic information and TNRS output be returned? Default is FALSE. |
political.boundaries |
Should political boundary information (country, state, etc.) be returned? Default is FALSE. |
source.citation |
Should readable source information be downloaded for each record? Note that |
... |
Additional arguments passed to internal functions. |
A dataframe of all data matching the specified families.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_family("Poaceae") family_vector<-c("Poaceae","Orchidaceae") BIEN_trait_family(family_vector) ## End(Not run)
## Not run: BIEN_trait_family("Poaceae") family_vector<-c("Poaceae","Orchidaceae") BIEN_trait_family(family_vector) ## End(Not run)
BIEN_trait_genus extracts entries that contain the specified genera.
BIEN_trait_genus( genus, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
BIEN_trait_genus( genus, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
genus |
A single genus or a vector of genera. |
all.taxonomy |
Should full taxonomic information and TNRS output be returned? Default is FALSE. |
political.boundaries |
Should political boundary information (country, state, etc.) be returned? Default is FALSE. |
source.citation |
Should readable source information be downloaded for each record? Note that |
... |
Additional arguments passed to internal functions. |
A dataframe of all data matching the specified genera.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_genus("Acer") genus_vector <- c("Acer","Abies") BIEN_trait_genus(genus_vector) ## End(Not run)
## Not run: BIEN_trait_genus("Acer") genus_vector <- c("Acer","Abies") BIEN_trait_genus(genus_vector) ## End(Not run)
BIEN_trait_list produces a dataframe of all available types of trait data.
BIEN_trait_list(...)
BIEN_trait_list(...)
... |
Additional arguments passed to internal functions. |
A dataframe containing all currently available types of trait data and details on measurement.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_list() ## End(Not run)
## Not run: BIEN_trait_list() ## End(Not run)
BIEN_trait_mean Estimates species mean values for a given trait, using Genus or Family level data where Species level data is absent.
BIEN_trait_mean(species, trait, ...)
BIEN_trait_mean(species, trait, ...)
species |
A single species or a vector of species. |
trait |
A single trait. |
... |
Additional arguments passed to internal functions. |
A dataframe of estimated trait means and associated metadata for the given species.
Trait spelling needs to be exact and case-sensitive, see BIEN_trait_list
for a list of traits.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_mean(species=c("Poa annua","Juncus trifidus"),trait="leaf dry mass per leaf fresh mass") ## End(Not run)
## Not run: BIEN_trait_mean(species=c("Poa annua","Juncus trifidus"),trait="leaf dry mass per leaf fresh mass") ## End(Not run)
BIEN_trait_species extracts trait data for the species specified.
BIEN_trait_species( species, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
BIEN_trait_species( species, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
species |
A single species or a vector of species. |
all.taxonomy |
Should full taxonomic information and TNRS output be returned? Default is FALSE. |
political.boundaries |
Should political boundary information (country, state, etc.) be returned? Default is FALSE. |
source.citation |
Should readable source information be downloaded for each record? Note that |
... |
Additional arguments passed to internal functions. |
A dataframe of all available trait data for the given species.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_species("Poa annua") species_vector<-c("Poa annua","Juncus trifidus") BIEN_trait_species(species_vector) ## End(Not run)
## Not run: BIEN_trait_species("Poa annua") species_vector<-c("Poa annua","Juncus trifidus") BIEN_trait_species(species_vector) ## End(Not run)
BIEN_trait_trait downloads all measurements of the trait(s) specified.
BIEN_trait_trait( trait, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
BIEN_trait_trait( trait, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
trait |
A single trait or a vector of traits. |
all.taxonomy |
Should full taxonomic information and TNRS output be returned? Default is FALSE. |
political.boundaries |
Should political boundary information (country, state, etc.) be returned? Default is FALSE. |
source.citation |
Should readable source information be downloaded for each record? Note that |
... |
Additional arguments passed to internal functions. |
A dataframe of all available trait data for the given trait(s).
Trait spelling needs to be exact and case-sensitive, see BIEN_trait_list
for a list of traits.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_trait("whole plant height") trait_vector<-c("whole plant height", "leaf dry mass per leaf fresh mass") BIEN_trait_trait(trait_vector) ## End(Not run)
## Not run: BIEN_trait_trait("whole plant height") trait_vector<-c("whole plant height", "leaf dry mass per leaf fresh mass") BIEN_trait_trait(trait_vector) ## End(Not run)
BIEN_trait_traitbyfamily extracts entries that contain the specified families and trait(s).
BIEN_trait_traitbyfamily( family, trait, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
BIEN_trait_traitbyfamily( family, trait, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
family |
A single family or a vector of families. |
trait |
A single trait or a vector of traits. |
all.taxonomy |
Should full taxonomic information and TNRS output be returned? Default is FALSE. |
political.boundaries |
Should political boundary information (country, state, etc.) be returned? Default is FALSE. |
source.citation |
Should readable source information be downloaded for each record? Note that |
... |
Additional arguments passed to internal functions. |
A dataframe of all data matching the specified trait(s) and family/families.
Trait spelling needs to be exact and case-sensitive, see BIEN_trait_list
for a list of traits.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_traitbyfamily(trait = "whole plant height", family = "Poaceae") trait_vector <- c("whole plant height", "leaf fresh mass") family_vector < -c("Orchidaceae","Poaceae") BIEN_trait_traitbyfamily(trait = trait_vector, family = family_vector) ## End(Not run)
## Not run: BIEN_trait_traitbyfamily(trait = "whole plant height", family = "Poaceae") trait_vector <- c("whole plant height", "leaf fresh mass") family_vector < -c("Orchidaceae","Poaceae") BIEN_trait_traitbyfamily(trait = trait_vector, family = family_vector) ## End(Not run)
BIEN_trait_traitbygenus extracts entries that contain the specified genus/genera and trait(s).
BIEN_trait_traitbygenus( genus, trait, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
BIEN_trait_traitbygenus( genus, trait, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
genus |
A single genus or a vector of genera. |
trait |
A single trait or a vector of traits. |
all.taxonomy |
Should full taxonomic information and TNRS output be returned? Default is FALSE. |
political.boundaries |
Should political boundary information (country, state, etc.) be returned? Default is FALSE. |
source.citation |
Should readable source information be downloaded for each record? Note that |
... |
Additional arguments passed to internal functions. |
A dataframe of all data matching the specified trait(s) and genus/genera.
Trait spelling needs to be exact and case-sensitive, see BIEN_trait_list
for a list of traits.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbyspecies()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_traitbygenus(trait = "whole plant height", genus = "Carex") trait_vector<-c("whole plant height", "leaf area") genus_vector<-c("Carex","Betula") BIEN_trait_traitbygenus(trait=trait_vector,genus=genus_vector) ## End(Not run)
## Not run: BIEN_trait_traitbygenus(trait = "whole plant height", genus = "Carex") trait_vector<-c("whole plant height", "leaf area") genus_vector<-c("Carex","Betula") BIEN_trait_traitbygenus(trait=trait_vector,genus=genus_vector) ## End(Not run)
BIEN_trait_traitbyspecies extracts entries that contain the specified species and trait(s).
BIEN_trait_traitbyspecies( species, trait, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
BIEN_trait_traitbyspecies( species, trait, all.taxonomy = FALSE, political.boundaries = FALSE, source.citation = FALSE, ... )
species |
A single species or a vector of species. |
trait |
A single trait or a vector of traits. |
all.taxonomy |
Should full taxonomic information and TNRS output be returned? Default is FALSE. |
political.boundaries |
Should political boundary information (country, state, etc.) be returned? Default is FALSE. |
source.citation |
Should readable source information be downloaded for each record? Note that |
... |
Additional arguments passed to internal functions. |
A dataframe of all data matching the specified trait(s) and species.
Trait spelling needs to be exact and case-sensitive, see BIEN_trait_list
for a list of traits.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traits_per_species()
## Not run: BIEN_trait_traitbyspecies(trait = "whole plant height", species = "Carex capitata") trait_vector<-c("whole plant height", "leaf area") species_vector<-c("Carex capitata","Betula nana") BIEN_trait_traitbyspecies(trait=trait_vector,species=species_vector) ## End(Not run)
## Not run: BIEN_trait_traitbyspecies(trait = "whole plant height", species = "Carex capitata") trait_vector<-c("whole plant height", "leaf area") species_vector<-c("Carex capitata","Betula nana") BIEN_trait_traitbyspecies(trait=trait_vector,species=species_vector) ## End(Not run)
BIEN_trait_traits_per_species downloads a count of the number of records for each trait for each species in the BIEN database.
BIEN_trait_traits_per_species(species = NULL, ...)
BIEN_trait_traits_per_species(species = NULL, ...)
species |
Optional species or vector of species. If left blank, returns counts for all species. |
... |
Additional arguments passed to internal functions. |
Returns a dataframe containing the number of trait records for each species in the BIEN database.
Other trait functions:
BIEN_trait_country()
,
BIEN_trait_family()
,
BIEN_trait_genus()
,
BIEN_trait_list()
,
BIEN_trait_mean()
,
BIEN_trait_species()
,
BIEN_trait_trait()
,
BIEN_trait_traitbyfamily()
,
BIEN_trait_traitbygenus()
,
BIEN_trait_traitbyspecies()
## Not run: trait_observation_counts<-BIEN_trait_traits_per_species() ## End(Not run)
## Not run: trait_observation_counts<-BIEN_trait_traits_per_species() ## End(Not run)