[Matplotlib-users] 3D scatter plot with 'unlimited' Z axis

Will Furnell mail at willfurnell.com
Mon Oct 1 15:40:17 EDT 2018

Hey everyone,

I'm looking into a 3D scatter plot - basically converting a NumPy array
to a 3D plot, where X and Y correspond to the X and Y co-ordinates on
the graph and the Z values corresponds to a particular height on the graph.

This is how I'm generating the lists:

x = list(range(0, 256))
y = list(range(0, 256))
z = []

for i in range(0, 255):
    for j in range(0, 255):

where ll is my 2D array...

I've seen the scatter function with 3d projection, but this requires the
Z array length to be the same length as the X and Y lengths, whereas
I'll need to be plotting X*Y points (256*256). Is there some way that I
could achieve this?



More information about the Matplotlib-users mailing list