Permalink
Browse files

Fix jittering resolution calculation. Fixes #572

  • Loading branch information...
1 parent 0719eed commit 5cce66c599678b1cf1d1e31fb9cd56b64023464a @wch wch committed Jul 5, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 R/position-jitter.r
View
@@ -33,8 +33,8 @@ PositionJitter <- proto(Position, {
if (empty(data)) return(data.frame())
check_required_aesthetics(c("x", "y"), names(data), "position_jitter")
- if (is.null(.$width)) .$width <- resolution(data$x) * 0.4
- if (is.null(.$height)) .$height <- resolution(data$y) * 0.4
+ if (is.null(.$width)) .$width <- resolution(data$x, zero = FALSE) * 0.4
+ if (is.null(.$height)) .$height <- resolution(data$y, zero = FALSE) * 0.4
trans_x <- NULL
trans_y <- NULL

0 comments on commit 5cce66c

Please sign in to comment.