ebv_map {ebvcube}R Documentation

Map plot of an EBV netCDF

Description

Map plot of the data of one timestep in one datacube of an EBV netCDF.

Usage

ebv_map(
  filepath,
  datacubepath,
  entity = NULL,
  timestep = 1,
  countries = TRUE,
  col_rev = FALSE,
  classes = 5,
  all_data = FALSE,
  ignore_RAM = FALSE,
  verbose = TRUE
)

Arguments

filepath

Character. Path to the netCDF file.

datacubepath

Character. Path to the datacube (use ebv_datacubepaths()).

entity

Character or Integer. Default is NULL. If the structure is 3D, the entity argument is set to NULL. Else, a character string or single integer value must indicate the entity of the 4D structure of the EBV netCDFs.

timestep

Integer. Choose one timestep.

countries

Logical. Default: TRUE. Simple country outlines will be plotted on top of the raster data. Disable by setting this option to FALSE.

col_rev

Logical. Default: FALSE Set to TRUE if you want the color ramp to be the other way around.

classes

Integer. Default: 5. Define the amount of classes (quantiles) for the symbology. Currently restricted to maximum 11 classes (allowed maximum for palette RdYlBu is 11).

all_data

Logical. Default: FALSE. The quantiles are based on the one timestep you chose (default). If you want include the full data of the datacube to produce several maps that are based on the same color scale, set this argument to TRUE (to allow for viusual comparison between entities or timesteps. Does not cover different datacubes.)

ignore_RAM

Logical. Default: FALSE. Checks if there is enough space in your memory to read the data. Can be switched off (set to TRUE).

verbose

Logical. Default: TRUE. Turn off additional prints by setting it to FALSE.

Value

Plots a map.

Examples


#set path to EBV netCDF
file <- system.file(file.path("extdata","martins_comcom_subset.nc"), package="ebvcube")
#get all datacubepaths of EBV netCDF
datacubes <- ebv_datacubepaths(file, verbose=FALSE)

#plot a map for the 3rd timestep, divide into 7 classes
ebv_map(filepath = file, datacubepath = datacubes[1,1], entity = 1,
        timestep = 3, classes = 7)


[Package ebvcube version 0.1.7 Index]