title: How to limit the contour plot with a line plot?
body: <p>Im trying to plot this contour until the #upperlimit coordinates on black, the results should be something like figure b (attached)<a href="https://i.stack.imgur.com/0mluJ.png" rel="nofollow noreferrer">figure</a></p>
  
  <p>The figure A is the output of next code:</p>
  
  <pre><code>from scipy.interpolate import griddata 
  import numpy as np 
  import matplotlib.pyplot as plt 
  
  
  M = np.array([[0.000000,1217.000000,594.503284],
      [4.500000,1183.886353,2099.999905],
      [9.000000,1220.000000,1071.599126],
      [13.500000,1184.565430,2099.999905],
      [18.000000,1219.000000,435.631812],
      [22.500000,1185.150635,2099.999905],
      [24.500000,1217.555542,320.541441],
      [27.000000,1185.427490,2099.999905],
      [31.500000,1216.000000,300.000012],
      [36.000000,1185.981445,2099.999905],
      [40.500000,1215.000000,306.778669],
      [45.000000,1186.629272,2099.999905],
      [49.500000,1216.000000,300.000012],
      [54.000000,1187.214478,2099.999905],
      [58.500000,1215.000000,300.000012],
      [63.000000,1187.893555,2099.999905],
      [67.500000,1218.000000,335.902870],
      [72.000000,1188.572510,2099.999905],
      [76.500000,1220.000000,359.615386],
      [81.000000,1189.282715,2099.999905],
      [85.500000,1224.000000,1382.480264],
      [90.000000,1189.992920,2099.999905],
      [94.500000,1225.000000,1206.023455],
      [99.000000,1190.578125,2099.999905]])
  
      #upper,limit
  h = np.array([[0.0,1217],
      [4.5,1217],
      [9.0,1220],
      [13.5,1219],
      [18.0,1219],
      [22.5,1218],
      [27.0,1217],
      [31.5,1216],
      [36.0,1215],
      [40.5,1215],
      [45.0,1216],
      [49.5,1216],
      [54.0,1215],
      [58.5,1215],
      [63.0,1217],
      [67.5,1218],
      [72.0,1219],
      [76.5,1220],
      [81.0,1222],
      [85.5,1224],
      [90.0,1225],
      [94.5,1225],
      [99.0,1224],
      [103.5,1225]])
  ##
      x=M[:,0] 
      y=M[:,1]
      z=M[:,2]
  ##  
  
      xi=np.linspace(0,100.,100.) 
      yi=np.linspace(1190,1225.,1225.) 
      X,Y= np.meshgrid(xi,yi) 
      Z = griddata((x, y), z, (X, Y),method='cubic') 
      plt.contourf(X,Y,Z)
      plt.colorbar()
      plt.plot(h[:,0],h[:,1],'black',linewidth=2)
      plt.scatter(x,y,marker ='o',c='k',s=10,zorder=10)
      plt.xlim(0,100)
      plt.ylim(1190,1225)
      plt.grid(True)
      plt.rc('grid',linestyle="-",color='black')
      plt.show()
  </code></pre>
  
  <p>the idea is to hide or delete the contour plot above the black line. I solved it on Matlab with a patch, any idea about the best way to solve it in python?</p>