title: Adjust ggplot legend
body: <p>I am trying to make the following changes to the ggplot below (partly illustrated in the picture provided):</p>
  <ul>
  <li>change shading legend to show economic cycle (shaded is a recession, no shade is an expansion)</li>
  <li>add additional legend to show economic variables (green is 'CLI' and red is 'Inflation Expectations&quot;)</li>
  </ul>
  <p>The code so far looks like this:</p>
  <pre><code>A &lt;- ggplot(Alldata, aes(Date)) + 
    geom_tile(aes(alpha = Recession, y = 1), 
              fill = &quot;grey&quot;, height = Inf) +
    scale_alpha_continuous(range = c(0, 1), breaks = c(0, 1))+
    geom_line(aes(y = stdINFEX), col = 'blue', size = .8)+
    ylab('')+
    theme(        axis.text.y=element_blank(),  #remove y axis labels
          axis.ticks.y=element_blank()  #remove y axis ticks
    )
  
      
  A
  
  B &lt;- A + geom_line(aes(y = CLI), col = 'green', size = .8) 
  
  B
  </code></pre>
  <p><img src="https://i.stack.imgur.com/4qCMW.png" alt="ggplot" /></p>