View source: R/RandR_webtool_makeOccPlots.R
makeOccPlot | R Documentation |
Produces a PNG image of occurrence records for a selected taxon suitable for use in the R&R webtool
makeOccPlot( taxonNames = NULL, extentStr = c("auto", "NSW", "Aust"), baseDataPath = NULL, useTaxonSubfolders = FALSE, outputPath = NULL )
taxonNames |
Character array. One or more taxon names to be processed |
extentStr |
Character. A flag indicating the bounds to which the map will be cropped. Must be one of "auto", "NSW" or "Aust" - see Details for more information |
baseDataPath |
Character. Path to the folder below which folders for each taxon will be found |
useTaxonSubfolders |
Logical. Are files in sub-folders using taxonNames entries? Default is FALSE. |
outputPath |
Character. Path to the folder into which output files will be written using a filename convention described in Details |
The function has been designed to work with a fixed structure and filename convention for input data. It is assumed that within the folder defined by the paramater baseDataPath, there is a sub-folder named for each taxon listed in the parameter taxonNames. Then, within each taxon sub-folder there is a file with a name structured as "genus_specificEpithet_herbariumRecords_filtered.csv" which has been produced by the functions fetchALA and filterALA in the package RandR.data.
Output files are placed in the folder defined in paramater outputPath with a name like "genus_specificEpithet_distibution.png". For example, "Neolitsea_dealbata_distribution.png".
The spatial bounds of the output map are set by the parameter extentStr which may have one of three values:
auto Bounds set to bounding box of the occurrence records with a 0.1 degree buffer
NSW Bounds set to encompass NSW
Aust Bounds set to encompass Australia
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.