setRtMargin | R Documentation |
Sets the right or top margin for graphs with secondary axes. Used After setting up the graphics environment, but before the call to the high-level graphics function to allocate space for an additional label and title.
setRtMargin(y, margin = c(NA, NA, NA, NA), right.labels = 7, right.log = FALSE, right.range = c(NA, NA)) setTopMargin(margin = c(NA, NA, NA, NA))
y |
the secondary y-axis data to be plotted, missing values are permitted and are ignored. |
margin |
incomplete plot margin specification, generally computed by
|
right.labels |
set up right-axis labels; the approximate number of labels. |
right.log |
logical, if |
right.range |
set right-axis range. |
The values for right.labels
, right.log
, and right.range
should be set exactly as in the call to addXY
.
The margin
is a numeric vector of length 4 specifying the bottom, left, top,
and right margins around the plot, as decriibed in by the mar
option in
par
. The function setTopMargin
only changes the third value and
the function setRtMargin
only changes the fourth value. The value for
margin
is typically the output from setGraph
or the defaults for
these functions.
The updated margin; only the right margin value is changed.
setLayout
, setGraph
,
addXY
## Not run: # See for examples of setRtMargin: demo(topic="RightAxisExample", package="smwrGraphs") # See for examples of setTopMargin: demo(topic="TopAxisExample", package="smwrGraphs") ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.