Compute extent of occurrences (EOO) for multiple taxa in square kilometers using geosphere package and provide SpatialPolygons used for EOO computation

EOO.computing(
  XY,
  exclude.area = FALSE,
  country_map = NULL,
  export_shp = FALSE,
  write_shp = FALSE,
  alpha = 1,
  buff.alpha = 0.1,
  method.range = "convex.hull",
  Name_Sp = "species1",
  buff_width = 0.1,
  method.less.than3 = "not comp",
  write_results = TRUE,
  file.name = "EOO.results",
  parallel = FALSE,
  NbeCores = 2,
  show_progress = TRUE
)

Arguments

XY

dataframe see Details

exclude.area

a logical, if TRUE, areas outside of country_map are cropped of SpatialPolygons used for calculating EOO. By default is FALSE

country_map

a SpatialPolygonsDataFrame or SpatialPolygons showing for example countries or continent borders. This shapefile will be used for cropping the SpatialPolygonsl if exclude.area is TRUE

export_shp

a logical, whether shapefiles should be exported or not, see Value. By default is FALSE

write_shp

a logical, if TRUE, export SpatialPolygons used for EOO computation as ESRI shapefiles in the working directory. By default is FALSE

alpha

a numeric, if method.range is "alpha.hull", value of alpha of the alpha hull, see ahull. By default is 1

buff.alpha

a numeric, if method.range is "alpha.hull", define the buffer in decimal degree added to alpha hull. By default is 0.1

method.range

a character string, "convex.hull" or "alpha.hull". By default is "convex.hull"

Name_Sp

a character string, if XY is for one taxon and field containing taxon names is not provided, this item provide taxon name. By default is "Species1"

buff_width

a numeric. For a specific case where all points of a taxa are on a straight line, see Details. By default is 0.1

method.less.than3

a character string. If equal to "arbitrary", will give a value to species with two unique occurrences, see Details. By default is "not comp"

write_results

a logical. If TRUE, results will be exported in the working environment as a csv file. By default is TRUE

file.name

a character string. Name file for exported results in csv file. By default is "EOO.results"

parallel

a logical. Whether running in parallel. By default, it is FALSE

NbeCores

an integer. Register the number of cores for parallel execution. By default, it is 2

show_progress

logical. Whether a progress bar should displayed. TRUE by default.

Value

If export_shp is FALSE, a dataframe with one field containing EOO in square kilometers. NA is given when EOO could not be computed because there is less than three unique occurrences (or two if method.less.than3 is put to "arbitrary").

If export_shp is TRUE, a list with:

  1. EOO in square kilometers

  2. SpatialPolygons used for EOO computation

Details

Input as a dataframe should have the following structure:

It is mandatory to respect field positions, but field names do not matter

[,1]ddlatnumeric, latitude (in decimal degrees)
[,2]ddlonnumeric, longitude (in decimal degrees)
[,3]taxcharacter or factor, taxa names

Important notes:

EOO will only be computed if there is at least three unique occurrences unless method.less.than3 is put to "arbitrary". In that specific case, EOO for species with two unique occurrences will be equal to Dist*Dist*0.1 where Dist is the distance in kilometers separating the two points.

For the very specific (and infrequent) case where all occurrences are localized on a straight line (in which case EOO would be null), EOO is estimated by the area of polygon surrounding this straight line with a buffer of buff.alpha decimal degree. There is a warning when this happen.

Limitation

For a species whose occurrences span more than 180 degrees, EOO is not computed. This is the case for example for species whose distribution span the 180th meridian.

References

Gaston & Fuller 2009 The sizes of species'geographic ranges, Journal of Applied Ecology, 49 1-9

See also

Examples

data(dataset.ex) data(land) if (FALSE) { EOO <- EOO.computing(dataset.ex) ## This exclude areas outside of land (i.e. ocean) for EOO computation EOO <- EOO.computing(dataset.ex, exclude.area=TRUE, country_map=land) }