Learn R Programming

bRacatus (version 2.0.0)

plotOcc: plotOcc

Description

Plot the species occurrences with map background for visualisation

Usage

plotOcc(occ, regional = TRUE)

Value

This function plots the species occurrence

Arguments

occ

dataTable of the species occurrence.

regional

logical, whether the whole world should be plotted as the background or only the region adjacent to the species countries of occurrence.

Examples

Run this code

# \donttest{
occ <- getOcc("Hemitriccus mirandae")

plotOcc(occ)

test_data <- data.frame(sps=rep("Equus acephalus",10),
             lon=c(-43.2,-58.4,-56,-44,-54.5,-57.4,-60.1,-68.5,-71.3,-47.5),
             lat=c(-22.9,-34.6,-34.8,-20,-25.5,-25.2,-3,-32.5,-41.1,-15.5),
             gender=rep("female",10),head_size=rep("headless individual"))

occ <- giveOcc(test_data,"sps","lon","lat")

plotOcc(occ)

# Plot occurrences with the whole world as background

plotOcc(occ,regional=FALSE)
# }

Run the code above in your browser using DataLab