title: Plotting continuous and discrete series in ggplot with facet
body: <p>I have data that plots over time with four different variables. I would like to combine them in one plot using facet_grid, where each variable gets its own sub-plot. The following code resembles my data and the way I'm presenting it:</p>
  
  <pre><code>require(ggplot2)
  require(reshape2)
  
  subm &lt;- melt(economics, id='date', c('psavert','uempmed','unemploy'))
  mcsm &lt;- melt(data.frame(date=economics$date, q=quarters(economics$date)), id='date')
  mcsm$value &lt;- factor(mcsm$value)
  
  
  ggplot(subm, aes(date, value, col=variable, group=1)) + geom_line() + 
         facet_grid(variable~., scale='free_y') + 
         geom_step(data=mcsm, aes(date, value)) + 
         scale_y_discrete(breaks=levels(mcsm$value))
  </code></pre>
  
  <p>If I leave out scale_y_discrete, R complains that I'm trying to combine discrete value with continuous scale. If I include scale_y_discreate my continuous series miss their scale.</p>
  
  <p>Is there any neat way of solving this issue ie. getting all scales correct ? I also see that the legend is alphabetically sorted, can I change that so the legend is ordered in the same order as the sub-plots ?</p>