rajesh j wrote:
Hi,

I wish to plot multiple histograms(representing different data so different
range along xaxis but y axis is the same) horizontally in ggplot2. I'd like
it to look like facets. Is this possible?

Can you give a small example, say, using the diamonds dataset, or one of your own? What's wrong with:

  data(diamonds)
  qplot(carat, data = diamonds,
        facets = color ~ .,
        geom = "histogram",
        binwidth = 0.1, xlim = c(0,3))

which is Figure 2.16 in the ggplot2 book. You can change this to be horizontal.

Unless you mean different variables completely, in which case you can create your own grid viewports, or possibly use the reshape package along with faceting. Without a concrette example, it's hard to offer more help.

______________________________________________
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