title: 3d surface in matplotlib
body: <p>I have referred to matplotlib.org and a lot of threads but I can't plot a 3d surface. I am able to plot a 3d scatter but as soon as I try to plot a 3d surface it breaks for a lot of different errors. I fix errors but I get new ones. After fighting with it for a 2 days I believe my understanding of matplotlib 3d surfaces is wrong. </p>
  
  <p>I want to plot SA,FZ, FY</p>
  
  <p>where SA is X, FZ is Y, FY is Z</p>
  
  <pre><code> while y&lt;Last_Row:
      if 100 &lt; Temp_AVG_Dict[y] and Temp_AVG_Dict[y] &lt; 140 and abs(Camber[y])&lt;5 and 24.5&lt;Speed[y] and Speed[y]&lt;25.5:
          y = y + 1
  
          SA[SArow:]=[Run_50_sheet.cell_value( y , SA_Column)]
          SArow = SArow + 1
  
          FY[FYrow:] = [Run_50_sheet.cell_value( y , FY_Column)]
          FYrow = FYrow + 1
  
          FZ[FZrow:] = [Run_50_sheet.cell_value( y , FZ_Column)]
          FZrow = FZrow + 1
  
          Z.insert(SArow,[SA[SArow-1], FZ[FZrow-1], FY[FYrow-1]])
  
      else:
          y=y+1
  
  Z= np.array(Z)
  
  
  fig = plt.figure(1)
  ax = fig.add_subplot(111, projection='3d')
  </code></pre>
  
  <p>This line below is where I believe I am going wrong. X,Y,Z need to all be 2d arrays but im unsure of the values that need to be input. </p>
  
  <p>I tried making 2d arrays in the order of [SA,FZ], [FZ,FY], and [SA,FY] but that failed
  I also tried making SA and FY equal to 1..n but that didn't work either.</p>
  
  <pre><code>ax.plot_surface( SA, FY ,Z)
  plt.show()
  </code></pre>
  
  <p>What values should the 2d arrays be made of? 
  Any help is appreciated.</p>