title: ggplot2 how to add different sets of colour palettes to different geom_ribbon?
body: <p>I'm trying to plot two types of time-series graphs. One in which the 'min-max' ribbon  is more transparent than the '10th-90h percentile' ribbon, but the colour is region-specific. In the other graph, I wish the colour of the ribbons to be both region and ribbon type specific. Could someone kindly help me? I'm adding below some code of a failed attempt to play with transparency (playing with alpha values doesn't really change the figure the way I'd expect)</p>
  
  <pre><code>library(ggplot2)
  library(RColorBrewer)
  cbPalette &lt;- c("red", "blue")
  
  test &lt;- data.frame(time=c("2018-04-30", "2018-05-31", "2018-06-30", "2018-07-31", "2018-08-31", "2018-09-30", "2018-04-30", "2018-05-31", "2018-06-30", "2018-07-31", "2018-08-31", "2018-09-30"), 
                     region=c("regionA","regionA","regionA","regionA","regionA","regionA", "regionB","regionB","regionB","regionB","regionB","regionB"),
                     minvalue=c(50, 70, 73, 97, 80, 65, 50, 70, 73, 97, 80, 65), 
                     maxvalue=c(70, 100, 100, 100, 90, 70, 70, 100, 100, 100, 90, 70), 
                     value90th=c(60, 90, 80, 98, 85, 69, 60, 90, 80, 98, 85, 69),
                     value10th=c(60, 80, 75, 97, 84, 67,60, 80, 75, 97, 84, 67),
                     addvalue=c(60, 80, 75, 50, 84, 67,60, 60, 75, 97, 84, 67))
  
  p &lt;- ggplot(test, aes(x=as.POSIXct(time)))
  p &lt;- p + facet_grid(region~.)
  p &lt;- p + geom_ribbon(aes(ymin = value10th, ymax = value90th, fill=region, alpha = 0.7))  
  p &lt;- p + geom_ribbon(aes(ymin = minvalue, ymax = maxvalue, fill=region, alpha = 0.6))+ scale_fill_manual(values=cbPalette)
  p &lt;- p + geom_line(aes(y=addvalue, colour="pink"), size=0.5) 
  p
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/lEfUL.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/lEfUL.png" alt="enter image description here"></a></p>