> I'm having the same problem as Stephan (see below), but what I'm trying to
> jitter is not a numeric vector, but a factor. How do I proceed? (Naively
> jittering a factor makes it numeric, no longer factor, so I don't get the
> custom ordering which conveniently comes with using a factor. I'm not sure
> how I would simulate that custom ordering with the jittered vector ... I
> couldn't find anything online about jittering factors, but maybe I just
> wasn't searching cleverly enough.)

You'll probably need to reorder the factor, then jitter it, and then
add custom labels with scale_continuous().  I think I see how to
resolve this problem in general (two displays of the same jittered
data), but it requires basically a complete rewrite of ggplot2, so
it's unlikely to appear before ggplot3.

Hadley


-- 
Assistant Professor / Dobelman Family Junior Chair
Department of Statistics / Rice University
http://had.co.nz/

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to