title: Trend between years on top of bar R
body: <p>I am trying to create a bar chart in R that shows data for two years at the same time. I want the top of each bar to show the slope between both years (and if possible include an arrow). </p>
  
  <p>It is easier to show an image of it. I have been able to do it in quite a fiddly way in Excel: <a href="https://i.stack.imgur.com/icLRf.png" rel="nofollow noreferrer">Excel chart</a></p>
  
  <p>This could be an example dataset:</p>
  
  <pre><code>cat &lt;- c("Item1", "Item2", "Item3")
  year1 &lt;- c(20,40,10)
  year2 &lt;- c(30,30,10)
  data &lt;- cbind(cat, year1, year2)
  </code></pre>
  
  <p>Anyone has any idea of how this could be done?</p>
  
  <p>Thank you!</p>