--
You received this message because you are subscribed to the ggplot2 mailing list.
Please provide a reproducible example: http://gist.github.com/270442
To post: email ggp...@googlegroups.com
To unsubscribe: email ggplot2+u...@googlegroups.com
More options: http://groups.google.com/group/ggplot2
Hi
Sorry, in my effort to make the example more simple than my real problem, I obscured what the actual problem was. In my actual dataset, I have 70 groups. The groups represent different species collected using different methods. So, some species are represented by only one group, while others are represented by multiple groups. I want separate histograms for each group, but I want to label them by species. The figure produced using facet_wrap(~group1) shows the data exactly as I want them, I just want to replace the labels with the species names (instead of the group number) without having to do it by hand.
Maybe I just need to change all the groups to something containing the species name, but it would be much easier to just change the labels if I can!
Thanks
Gretchen
If there's a one-to-one correspondence between species and group, then
I don't see why you can't facet by species. If there isn't a
one-to-one correspondence, then how do you figure out the species
label?
Hadley
--
Assistant Professor / Dobelman Family Junior Chair
Department of Statistics / Rice University
http://had.co.nz/
You can, using a customised labeller function, but it's easier just to
create new variable (and, regardless, I still don't see how it would
help with your problem).
Hadley