clim_plot: plots ".gz"-file climatologies

View source: R/clim_plot.r

clim_plotR Documentation

plots '.gz'-file climatologies

Description

Creates climatology plots of '.gz'-files. ATTENTION! This function requires an ImageMagick installation, but runs also under Windows operating systems.

Usage

clim_plot(obj, folder,plotfolder=".", plotname, question=T, sst.frontcolor='red', 
          chla.frontcolor='blue', sidelabels = F, Ylab = F, axeslabels = T, v_area, ...)

Arguments

obj

Character string indicating search criteria for climatology '.gz'-files.

folder

directory where data files are located (optional).

plotfolder

directory where image should be saved.

plotname

the name of the output file. If not provided, value will be derived from '.gz'-filenames.

question

whether the user shall be informed about the number of figures to plot before running the procedure (default is TRUE).

chla.frontcolor

color map to be plotted for chlorophyll fronts (default is blue; obtained from cmap-dataset)

sst.frontcolor

color map to be plotted for sea surface temperature fronts (default is red; obtained from cmap-dataset)

sidelabels

whether an additional y-axis label and title should be added to the plot device (default is FALSE). If TRUE, y-axis label is defined by Ylab, the additional title is derived from the date-information and gives the month information.

Ylab

an additional title for the y axis (default is date information), only used when sidelabels is set TRUE. Default value is year-information.

axeslabels

whether axeslabels should be shown (default is TRUE, set as 'longitude' and 'latitude')

v_area

character string identifying the region that should be plotted, or in case of obj == 'bathy', also a Raster* or Extent object. If missing, region is derived from the '.gz'-filename. See region_definitions for area definitions and use add.region to add new regions.

...

Additional arguments to be passed to v and plotmap (e.g. main, sidelabels, Ylab, scale_arrow, minv, maxv, adaptive.vals, cb.xlab, suffix, v_area, v_image, v_contour, v_arrows, fill, col, border, grid, grid.res, bwd, axeslabels, ticklabels, cex.lab, cex.ticks)

Author(s)

Robert K. Bauer

See Also

v, readbin, name_split, regions, plotmap

Examples

## Example 1: plot seasonal '.gz'-files, following default plot-procedure
path <- system.file("test_files", package="oceanmap")
gz.file <- Sys.glob(paste0(path,'/*.gz'))[1] # load sample-'.gz'-files
check_gzfiles(folder=path) # return file summary-table
gz.files <- Sys.glob(paste0(path,'/*1s_*.gz')) # load seasonal '.gz'-files
# v(gz.files) # as single plots

## as combined climatology plot, saved in plotfolder
# clim_plot(gz.files,plotname='chla.summary.png') 

oceanmap documentation built on Nov. 10, 2023, 5:08 p.m.

Related to clim_plot in oceanmap...