title: plotting 3D surface using python: raise ValueError("Argument Z must be 2-dimensional.") matplotlib
body: <p>I'm trying to plot a 3d surface passes through a set of (X,Y,Z) 3d point and I got  raise ValueError("Argument Z must be 2-dimensional.") matplotlib </p>
  
  <pre><code>points = Tail_geo(D,L) # is a list from a function 
  points = points + Nose_geo(D,L)# is a list from both function s
  X = [x[0] for x in points]# seperate X from the list
  Y = [x[1] for x in points]
  Z = [x[2] for x in points]
  X = np.asarray(X)
  Y = np.asarray(Y)
  Z = np.asarray(Z)
  fig = plt.figure()
  ax = fig.gca(projection='3d')
  surf = ax.plot_surface(X, Y, Z, linewidth=0, antialiased=False)
  plt . show ( )
  </code></pre>