Skip to content

Commit d900655

Browse files
author
murrell
committed
fix to error messages and docs for grid::dataViewport(). Thanks to Avinab Neogy
git-svn-id: https://svn.r-project.org/R/trunk@87840 00db46b3-68df-0310-9c12-caf00c1e9a41
1 parent 59ccaa8 commit d900655

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/library/grid/R/viewport.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -454,12 +454,12 @@ dataViewport <- function(xData = NULL, yData = NULL,
454454
extension <- rep(extension, length.out = 2)
455455
if (is.null(xscale)) {
456456
if (is.null(xData))
457-
stop("must specify at least one of 'x' or 'xscale'")
457+
stop("must specify at least one of 'xData' or 'xscale'")
458458
xscale <- extendrange(xData, f = extension[1L])
459459
}
460460
if (is.null(yscale)) {
461461
if (is.null(yData))
462-
stop("must specify at least one of 'y' or 'yscale'")
462+
stop("must specify at least one of 'yData' or 'yscale'")
463463
yscale <- extendrange(yData, f = extension[2L])
464464
}
465465
viewport(xscale = xscale, yscale = yscale, ...)

src/library/grid/man/dataViewport.Rd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ dataViewport(xData = NULL, yData = NULL, xscale = NULL,
2727
the \code{viewport()} function. }
2828
}
2929
\details{
30-
If \code{xscale} is not specified then the values in \code{x} are
31-
used to generate an x-scale based on the range of \code{x}, extended
30+
If \code{xscale} is not specified then the values in \code{xData} are
31+
used to generate an x-scale based on the range of \code{xData}, extended
3232
by the proportion specified in \code{extension}. Similarly for the
3333
y-scale.
3434
}

0 commit comments

Comments
 (0)