title: Change y range to start from 0 with matplotlib
body: <p>I am using matplotlib to plot data. Here's a code that does something similar:</p>
  
  <pre><code>import matplotlib.pyplot as plt
  f, ax = plt.subplots(1)
  xdata = [1, 4, 8]
  ydata = [10, 20, 30]
  ax.plot(xdata, ydata)
  plt.show(f)
  </code></pre>
  
  <p>This shows a line in a graph with the y axis that goes from 10 to 30. While I am satisfied with the x range, I would like to change the y range to start from 0 and adjust on the ymax to show everything.</p>
  
  <p>My current solution is to do:</p>
  
  <pre><code>ax.set_ylim(0, max(ydata))
  </code></pre>
  
  <p>However I am wondering if there is a way to just say: autoscale but starts from 0.</p>