title: How to rotate labels using bar_label in matplotlib?
body: <ol>
  <li><p>How do I rotate the labels by 90 degree in a bar chart using <code>matplotlib.bar_label()</code>? <a href="https://i.stack.imgur.com/gJ7WT.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/gJ7WT.png" alt="enter image description here" /></a></p>
  </li>
  <li><p>In the <a href="https://matplotlib.org/3.5.1/api/_as_gen/matplotlib.pyplot.bar_label.html" rel="nofollow noreferrer">documentation</a> of <code>matplotlib.bar_label()</code>, can you explain usage of below argument with some example?</p>
  </li>
  </ol>
  <blockquote>
  <p>**kwargs: Any remaining keyword arguments are passed through to Axes.annotate.</p>
  </blockquote>
  <pre><code>#CODE TO PRODUCE ABOVE SHOWN CHART
  
  labels = ['G1', 'G2', 'G3', 'G4', 'G5']
  men_means = [20, 34, 30, 35, 27]
  women_means = [25, 32, 34, 20, 25]
  
  x = np.arange(len(labels))  # the label locations
  width = 0.35  # the width of the bars
  
  fig, ax = plt.subplots()
  rects1 = ax.bar(x - width/2, men_means, width, label='Men')
  rects2 = ax.bar(x + width/2, women_means, width, label='Women')
  
  # Add some text for labels, title and custom x-axis tick labels, etc.
  ax.set_ylabel('Scores')
  ax.set_title('Scores by group and gender')
  ax.set_xticks(x, labels)
  ax.legend()   
  
  ax.bar_label(rects1, labels=[&quot;ABC&quot;,&quot;ABC&quot;,&quot;ABC&quot;,&quot;ABC&quot;,&quot;ABC&quot;], padding=3, label_type='center')
  ax.bar_label(rects2, labels=[&quot;DEF&quot;,&quot;DEF&quot;,&quot;DEF&quot;,&quot;DEF&quot;,&quot;DEF&quot;], padding=3, label_type='center')
  
  fig.tight_layout()
  
  plt.show()
  </code></pre>