title: Align vertically two plots in matplotlib provided one is an imshow plot?
body: <p>I want to align the x-axis of two plots, provided one is an <code>imshow</code> plot.</p>
  
  <p>I have tried to use <code>gridspec</code> as it follows:</p>
  
  <pre><code>import matplotlib.pyplot as plt
  import numpy as np
  import matplotlib.gridspec as grd
  
  v1 = np.random.rand(50,150)
  v2 = np.random.rand(150)
  
  fig = plt.figure()
  
  gs = grd.GridSpec(2,1,height_ratios=[1,10],wspace=0)
  
  
  ax = plt.subplot(gs[1])
  p = ax.imshow(v1,interpolation='nearest')
  cb = plt.colorbar(p,shrink=0.5)
  plt.xlabel('Day')
  plt.ylabel('Depth')
  cb.set_label('RWU')
  plt.xlim(1,140)
  
  #Plot 2
  ax2 = plt.subplot(gs[0])
  ax2.spines['right'].set_visible(False)
  ax2.spines['top'].set_visible(False)
  ax2.xaxis.set_ticks_position('bottom')
  ax2.yaxis.set_ticks_position('left')
  x=np.arange(1,151,1)
  ax2.plot(x,v2,'k',lw=0.5)
  plt.xlim(1,140)
  plt.ylim(0,1.1)
  #
  plt.savefig("ex.pdf", bbox_inches='tight') 
  </code></pre>
  
  <p>I also want the plots as close as possible to each other and one 1/10 the height of the other. If I take the colorbar out, they seem to aligned but still I can't put them close to each other. I also want the colorbar too.</p>