I'm seeing strange results when I combine facet_grid and
position_jitter. I'm using geom_jitter to try to cope with over-
plotting (I tried position="dodge" but that didn't seem to have any
effect with geom_point).
With position_jitter & facet_grid (scale and space free):
I suspect you want the dot plots in the attached paper.
Unfortunately, implementing it is non-trivial because you need to know
the size of the plots, which you can't figure that out until the plot
is actually drawn, which means you need to make a new class of grid
grobs, which is non-trivial and something I've been meaning to do for
ages, but haven't yet had a chance.
Regards,
Hadley
Very interesting. I think this is clearly related, although I hadn't
wanted to use it to look at distributions, but more for a combination
of sequential patterns and temporal-clustering.
These graphics are quite close, but overly unwieldy for research
papers and not good for comparing patterns:
http://simile-widgets.googlecode.com/svn/timeline/tags/latest/src/webapp/examples/monet/monet.html
But the dot plots are very close in spirit and the algorithm, I think,
would be basically the same.
--J
I'm a little confused and think there might have been a regression in
0.8.1 (which I'm using now) (or at least I forgot what I was doing
right before!)
The attached script used to produce a plot where the two facets didn't
have empty lines, but now it acts as it used to producing empty lines
in each facet. I think this is something to do with drop.levels being
needed (I imagine that subset is used somewhere to create the facets,
unused factors are not automatically dropped, one needs to use a
function like this:
# function to drop unused levels after a subset
drop.levels <- function(dat){
dat[] <- lapply(dat, function(x) x[,drop=TRUE])
return(dat)
}