[SciPy-User] creating a 3D surface plot from collected data
Mon Feb 15 10:47:18 CST 2010
Example here that might help.
Mobile: 07788 872118
All science is either physics or stamp collecting.
On 15 February 2010 14:17, URI <email@example.com> wrote:
> I am trying to figure out how to create a 3D surface plot from some x,y,z
> that I have. I don't have any particular preference as to how to do it,
> from poking around on the web it seems like mplot3d should be able to do
> based on what I see in the tutorial (look at the wireframe or surface plot
> The problem I have is that none of the example source code is based on
> with numbers from actual data. The only thing I could find that addresses
> issue is at the very bottom of this page under the heading "Another
> I've tried to duplicate this method but I get errors, and I don't really
> understand it anyway. The place I get lost is here:
> Z = numpy.zeros((len(Y), len(X)), 'Float32')
> for d in data:
> x, y, z = d
> ix = int(x * 10)
> iy = int(y * 10)
> Z[iy, ix] = z
> I don't understand how ix and iy are supposed to give me valid indeces for
> the Z
> array (and Python doesn't seem to understand it either, it gives me an
> error at
> that last line).
> Can someone either explain this method to me, or point me in a different
> SciPy-User mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the SciPy-User