Skip to content
Browse files

Fixes for R CMD check

  • Loading branch information...
1 parent 5c07c4c commit 7690e12be894e680a0f986c6ed578bc673b02916 @hadley committed May 7, 2012
View
3 DESCRIPTION
@@ -35,7 +35,8 @@ Suggests:
gpclib,
maptools,
multcomp,
- nlme
+ nlme,
+ testthat
Extends:
sp
License: GPL-2
View
5 NAMESPACE
@@ -328,6 +328,7 @@ S3method(interleave,default)
S3method(interleave,list)
S3method(interleave,unit)
S3method(is.linear,cartesian)
+S3method(is.linear,default)
S3method(is.linear,flip)
S3method(limits,character)
S3method(limits,Date)
@@ -353,6 +354,8 @@ S3method(rweave,matrix)
S3method(scale_break_info,continuous)
S3method(scale_break_info,discrete)
S3method(scale_breaks_minor,continuous)
+S3method(scale_breaks_minor,date)
+S3method(scale_breaks_minor,datetime)
S3method(scale_breaks_minor,discrete)
S3method(scale_breaks,continuous)
S3method(scale_breaks,discrete)
@@ -363,6 +366,8 @@ S3method(scale_dimension,continuous)
S3method(scale_dimension,discrete)
S3method(scale_dimension,position_d)
S3method(scale_expand,default)
+S3method(scale_is_empty,default)
+S3method(scale_is_empty,position_d)
S3method(scale_labels,continuous)
S3method(scale_labels,discrete)
S3method(scale_limits,default)
View
4 R/annotation-logticks.r
@@ -70,10 +70,10 @@
#' a + annotation_logticks(short = unit(.5,"mm"), mid = unit(3,"mm"), long = unit(4,"mm"))
#'
annotation_logticks <- function (base = 10, sides = "bl", scaled = TRUE,
- short = unit(0.1, "cm"), mid = unit(0.2, "cm"), long = unit(0.3, "cm"), ...) {
+ short = unit(0.1, "cm"), mid = unit(0.2, "cm"), long = unit(0.3, "cm")) {
GeomLogticks$new(base = base, sides = sides, raw = raw, scaled = scaled,
- short = short, mid = mid, long = long, ...)
+ short = short, mid = mid, long = long)
}
GeomLogticks <- proto(Geom, {
View
1 R/coord-.r
@@ -79,6 +79,7 @@ coord_distance <- function(coord, x, y, details)
UseMethod("coord_distance")
is.linear <- function(coord) UseMethod("is.linear")
+#' @S3method is.linear default
is.linear.default <- function(coord) FALSE
#' Set the default expand values for the scale, if NA
View
1 R/coord-cartesian-.r
@@ -7,6 +7,7 @@
#'
#' @param xlim limits for the x axis
#' @param ylim limits for the y axis
+#' @param wise deprecated in 0.9.1
#' @export
#' @examples
#' # There are two ways of zooming the plot display: with scales or
View
5 R/coord-transform.r
@@ -7,8 +7,9 @@
#' All current transformations only work with continuous values - see \code{scale}{trans_new}
#' for list of transformations, and instructions on how to create your own.
#'
-#' @param ytrans transformer for x axis
-#' @param xtrans transformer for y axis
+#' @param xtrans,ytrans transformers for x and y axes
+#' @param limx,limy limits for x and y axes. (Named so for backward
+#' compatability)
#' @export
#' @examples
#' \donttest{
View
7 R/scale-.r
@@ -156,6 +156,8 @@ scale_reset.default <- function(scale, x) {
}
scale_is_empty <- function(scale) UseMethod("scale_is_empty")
+
+#' @S3method scale_is_empty default
scale_is_empty.default <- function(scale) {
is.null(scale$range$range) && is.null(scale$limits)
}
@@ -380,7 +382,9 @@ scale_breaks_minor.continuous <- function(scale, n = 2, b = scale_break_position
discard(breaks, limits)
}
-scale_breaks_minor.date <- function(scale, n = 2, b = scale_break_positions(scale), limits = scale_limits(scale)) {
+#' @S3method scale_breaks_minor date
+scale_breaks_minor.date <- function(scale, n = 2, b =
+scale_break_positions(scale), limits = scale_limits(scale)) {
limits <- scale$trans$inv(limits)
if (zero_range(as.numeric(limits))) {
@@ -410,6 +414,7 @@ scale_breaks_minor.date <- function(scale, n = 2, b = scale_break_positions(scal
# Any minor breaks outside the dimensions need to be thrown away
breaks <- censor(scale$trans$trans(breaks), scale_limits(scale))
}
+#' @S3method scale_breaks_minor datetime
scale_breaks_minor.datetime <- scale_breaks_minor.date
#' @S3method scale_breaks_minor discrete
View
1 R/scale-discrete-.r
@@ -89,6 +89,7 @@ scale_limits.position_d <- function(scale) {
scale$limits %||% scale$range$range %||% dis_limits(scale$range_c$range)
}
+#' @S3method scale_is_empty position_d
scale_is_empty.position_d <- function(scale) {
NextMethod() && is.null(scale$range_c$range)
}
View
1 inst/tests/test-aes-grouping.r
@@ -1,4 +1,5 @@
context("Aesthetics (grouping)")
+library(plyr)
df <- data.frame(
x = 1:4,
View
2 man/annotation_logticks.Rd
@@ -4,7 +4,7 @@
\usage{
annotation_logticks(base = 10, sides = "bl",
scaled = TRUE, short = unit(0.1, "cm"),
- mid = unit(0.2, "cm"), long = unit(0.3, "cm"), ...)
+ mid = unit(0.2, "cm"), long = unit(0.3, "cm"))
}
\arguments{
\item{base}{the base of the log (default 10)}
View
2 man/coord_cartesian.Rd
@@ -8,6 +8,8 @@
\item{xlim}{limits for the x axis}
\item{ylim}{limits for the y axis}
+
+ \item{wise}{deprecated in 0.9.1}
}
\description{
The Cartesian coordinate system is the most familiar, and
View
2 man/coord_fixed.Rd
@@ -12,6 +12,8 @@
\item{xlim}{limits for the x axis}
\item{ylim}{limits for the y axis}
+
+ \item{wise}{deprecated in 0.9.1}
}
\description{
A fixed scale coordinate system forces a specified ratio
View
5 man/coord_trans.Rd
@@ -6,9 +6,10 @@
limx = NULL, limy = NULL)
}
\arguments{
- \item{ytrans}{transformer for x axis}
+ \item{xtrans,ytrans}{transformers for x and y axes}
- \item{xtrans}{transformer for y axis}
+ \item{limx,limy}{limits for x and y axes. (Named so for
+ backward compatability)}
}
\description{
\code{coord_trans} is different to scale transformations

0 comments on commit 7690e12

Please sign in to comment.
Something went wrong with that request. Please try again.