SeasOpts: Options for seas

SeasOptsR Documentation

Options for seas

Description

Set default options for seas.

Usage

setSeasOpts()

Details

setSeasOpts sets all the default values for options in seas, and at some point it may support arguments for styles, such as ‘black and white’. However, after the initial setting of options, users may change the options to modify the look of graphics produced in seas.

Other details of the graphics can be modified using par. This includes the font sizes, back-ground colour, font family, and many others. For example, setting par(cex=0.75) will reduce the font size in the active device by 75% of the original size; while par(font.main=2) will change only the font for the main titles.

Value

setSeasOpts() only sets the options in the current environment, and returns nothing.

This is automatically done when seas is loaded (using .onLoad).

Options used in seas

Here are all the supported options for seas, with the default values shown for each option. Options are stored in lists, which make them easy to ‘get’, but difficult to ‘set’, and is shown in the Examples section at the bottom.

seas.main:

formating style for main title:

fmt:

format for name and id (if available) as the first "%s", followed by a range of years as the second "%s"; these are formated by sprintf; "%s\n%s"

rngsep:

separation between ranges of years; "-", other alternatives could be " to "

show.id:

show id (if available) in main title; TRUE

show.fun:

show function (where applicable) in main title; TRUE

seas.label:

label formating for variables:

fmt:

label for name and units (if available); "%s (%s)", other alternatives could be "%s, %s"

monthday:

format for month and day (see strftime for format codes); this can be either "%b %-d" (for most Unix-like systems), "%b %#d" (for Windows systems), or "%b %d" (for other systems); this should produce a string, such as ‘Aug 1’ for August 1st

month

similar as previous, but when starting exactly on month-breaks; "%B"

ann

a label for image.seas.sum; default is ‘annual’

seas.month.grid:

setting for the display of the month grid (see .seasmonthgrid), which is common to many plots that use a numeric width in mkseas:

abb:

abbreviate month names for grid; TRUE

len:

trim month name lengths to a number, for instance to get J|F|M|A|M|J|J|A|S|O|N|D, use 1; NULL

force:

force the display of each month label using mtext, otherwise labels can be automatically placed and adjusted for device using axis; TRUE

label:

show a month label on the grid; TRUE

col:

colour for month grid; "lightgrey"

lwd:

width for month grid lines, multiplied by par("lwd"); 1

lty:

style for month grid lines; 1

seas.bxp:

attributes which affect the display of boxplots, used by various functions:

boxcol:

default box-fill colour; "lightgrey"

outcex:

outlier symbol size, multiplied by par("cex"); 1

seas.temp:

attributes which affect the display of seas.temp.plot (among other functions):

col:

colours for boxplot fill and diurnal variability lines; c("lightgrey","red")

lwd:

width of diurnal variability lines in seas.temp.plot, multiplied by par("lwd"); 3

seas.precip:

attributes which affect the display of precipitation:

col:

colour; "grey"

density:

pattern density; NULL

angle:

pattern angel; 45

lwd:

thickness of box line, multiplied by par("lwd"); 1

seas.rain:

attributes which affect the display of rain:

col:

colour; "lightblue"

density:

pattern density; NULL

angle:

pattern angel; 45

lwd:

thickness of box line, multiplied by par("lwd"); 1

seas.snow:

attributes which affect the display of snow:

col:

colour; "lightgrey"

density:

pattern density; NULL

angle:

pattern angel; -45

lwd:

thickness of box line, multiplied by par("lwd"); 1

seas.interarrival:

attributes which affect the display of wet- and dry-spells in plot.interarrival; organized as c(wet,dry):

col:

colour; c("lightblue","orange")

seas.median:

attributes which affect the display of the median lines in image.seas.sum:

col:

colour; "red"

lwd:

width of line, multiplied by par("lwd"); 1

lty:

style of line; 1

seas.mean:

attributes which affect the display of the mean lines in image.seas.sum:

col:

colour; "red"

lwd:

width of line, multiplied by par("lwd"); 1

lty:

style of line; 1

seas.na:

attributes which affect the display of NA or missing values in various plots:

col:

colour; "red"

pch:

character symbol; "x"

Author(s)

Mike Toews

See Also

hidden

Examples

if(is.null(getOption("seas.main")))
  setSeasOpts()

# Modify an option
getOption("seas.main")$show.id
cp <- orig <- getOption("seas.main")
cp$show.id <- FALSE
options(seas.main=cp)
getOption("seas.main")$show.id

options(seas.main=orig)

seas documentation built on May 2, 2022, 5:08 p.m.