Learn R Programming

BIEN (version 1.2.6)

BIEN_ranges_species_bulk: Extract range data for large numbers of species

Description

BIEN_ranges_species_bulk downloads ranges for a large number of species using parallel processing.

Usage

BIEN_ranges_species_bulk(
  species = NULL,
  directory = NULL,
  batch_size = 1000,
  return_directory = TRUE,
  use_parallel = FALSE
)

Value

Optionally, the directory to which the files were saved.

Arguments

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.

See Also

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()

Examples

Run this code
if (FALSE) {
#To download all BIEN ranges maps:
BIEN_ranges_species_bulk()
}

Run the code above in your browser using DataLab