I have three 1D NumPy Arrays XX, YY, and ZZ. They are organized such that ZZ[i] is the height of a hill at coordinates XX[i], YY[i]. How can I plot this using Python?
Edit: The arrays are quite large (each contain about 3e5 data points)
Edit 2: I want a surface plot
Thanks
matplotlibfor surface plots. But you first need to re-organise your arrays on a regular grid. You can use thisax.plot_surfacewith reshaped x, y and z is recommended. If the input x and y are irregular spaced, [ax.trisurf3d](ax.matplotlib.org/stable/gallery/mplot3d/trisurf3d.html) will work.ax.trisurf3dfixed it.