title: Stacked histogram from already summarized counts using ggplot2
body: <p>I would like some help coloring a ggplot2 histogram generated from already-summarized count data. </p>
  
  <p>The data are something like counts of # males and # females living in a number of different areas.  It's easy enough to plot the histogram for the total counts (i.e. males + females): </p>
  
  <pre><code>set.seed(1)
  N=100;
  X=data.frame(C1=rnbinom(N,15,0.1), C2=rnbinom(N,15,0.1),C=rep(0,N)); 
  X$C=X$C1+X$C2;
  ggplot(X,aes(x=C)) + geom_histogram()
  </code></pre>
  
  <p>However, I'd like to color each bar according to the relative contribution from C1 and C2, so that I get the same histogram (i.e. overall bar heights) as in the above example, plus I see the proportion of type "C1" and "C2" individuals as in a stacked bar chart. </p>
  
  <p>Suggestions for a clean way to do this with ggplot2, using data like "X" in the example?</p>