setlimits1D {adegraphics} | R Documentation |
Computes limits for 1D and 2D displays.
Description
Computes limits for 1D and 2D displays adding 10% of margins around the extreme values.
Usage
setlimits1D(mini, maxi, origin, includeOr)
setlimits2D(minX, maxX, minY, maxY, origin = c(0, 0), aspect.ratio = "iso", includeOr)
Arguments
mini |
the smallest value of a unidimensional dataset |
maxi |
the largest value of a unidimensional dataset |
minX |
the smallest value of the first dimension of a bidimensional dataset |
maxX |
the largest value of the first dimension of a bidimensional dataset |
minY |
the smallest value of the second dimension of a bidimensional dataset |
maxY |
the largest value of the second dimension of a bidimensional dataset |
origin |
a value (in |
aspect.ratio |
a character string to control physical aspect ratio of the graphic.
|
includeOr |
a boolean value indicating whether the origin is included in the graphics window |
Value
setlimits1D
returns a two-length vector containing the limits of the graphics window on one axis.
setlimits2D
returns a two-length list where the first element, named xlim
, contains a two-length vector
containing the limits of the graphics window on the first axis and the second, named ylim
, contains the limits on
the second axis.
Author(s)
Alice Julien-Laferriere, Aurelie Siberchicot aurelie.siberchicot@univ-lyon1.fr and Stephane Dray
Examples
setlimits1D(mini = -2, maxi = 2, origin = 0, includeOr = TRUE)
setlimits2D(minX = -2, maxX = 2, minY = -3, maxY = 4, origin = c(0, 0), includeOr = TRUE)