title: Pandas & Matplotlib: personalize the date format in a line chart
body: <p>I want to make the dates on the x- axis look more prettier, currently the dates cannot be even read. what is the best way to do it.
  Below is the code and also the actual graph picture</p>
  
  <pre><code>import matplotlib.pyplot as plt
  import pandas as pd
  import pandas as pd
  
  df = dataset
  # gca stands for 'get current axis'
  ax = plt.gca()
  y1 = df['Predicted_Lower']
  y2 = df['Predicted_Upper']
  x = df['Date']
  ax.fill_between(x,y1, y2, facecolor="#CC6666", alpha=0.7)
  df.plot(kind='line',x='Date',y='Predicted_Lower',color='white',ax=ax)
  df.plot(kind='line',x='Date',y='Predicted_Upper',color='white', ax=ax)
  df.plot(kind='line',x='Date',y='Predicted', color='yellow', ax=ax)
  df.plot(kind='line',x='Date',y='Actuals', color='green', ax=ax)
  plt.xticks(rotation=45)
  
  plt.show()
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/4kBWV.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/4kBWV.png" alt="enter image description here"></a></p>