buffer_b: Create buffer based on species polygons

View source: R/1.1.f.data.prep.R

buffer_bR Documentation

Create buffer based on species polygons

Description

This funcion will create a buffer using species polygons. Buffer width may be manually specified or calculated based on the extent of the SpatialPolygons object (i.e. mean of latitudinal and longitudinal extent). If width is calculated based on the extent of the SpatialPolygons object, it can be adjusted (enlarged or reduced) using 'mult' argument.

Usage

buffer_b(
  occ.polys,
  width = NULL,
  mult = 0.2,
  numCores = 1,
  crs.set = NULL,
  plot = F
)

Arguments

occ.polys

list of SpatialPolygons, usually obj returned from set_calibarea_b()

width

numeric > 0. Unit is meter if x has a longitude/latitude CRS, or mapunits in other cases

mult

How much expand width

numCores

Number of cores to use for parallelization. If set to 1, no paralellization is performed

crs.set

set the coordinate reference system (CRS) of the polygons

plot

logical. Plot results or not?

Value

A named list of SpatialPolygons

See Also

buffer, set_calibarea_b

Examples

## Not run: 
Bvarieg.occ <- read.table(paste(system.file(package="dismo"),
 "/ex/bradypus.csv", sep=""), header=TRUE, sep=",")
colnames(Bvarieg.occ) <- c("SPEC", "LONG", "LAT")
spp.occ.list <- list(Bvarieg = Bvarieg.occ)
occ.polys <- set_calibarea_b(spp.occ.list)
occ.b <- buffer_b(occ.polys, width=150000)

## End(Not run)

HemingNM/ENMwizard documentation built on Jan. 4, 2024, 3:24 p.m.