.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "11_demos\python_packages\matplotlib\demo_surface3d.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note Click :ref:`here ` to download the full example code .. rst-class:: sphx-glr-example-title .. _sphx_glr_11_demos_python_packages_matplotlib_demo_surface3d.py: Surface 3D ============= .. GENERATED FROM PYTHON SOURCE LINES 5-30 .. image-sg:: /11_demos/python_packages/matplotlib/images/sphx_glr_demo_surface3d_001.png :alt: demo surface3d :srcset: /11_demos/python_packages/matplotlib/images/sphx_glr_demo_surface3d_001.png :class: sphx-glr-single-img .. code-block:: default from itom import dataObject import matplotlib.pyplot as plt import numpy as np data = dataObject.randN([55, 56]) [rows, cols] = data.shape X = np.arange(rows) Y = np.arange(cols) Xaxis3D, Yaxis3D = np.meshgrid(Y, X) fig = plt.figure() ax = fig.add_subplot(111, projection="3d") ax.plot_surface( Yaxis3D, Xaxis3D, data, rstride=1, cstride=1, cmap=plt.cm.Spectral, linewidth=0, antialiased=False, ) plt.show() .. rst-class:: sphx-glr-timing **Total running time of the script:** ( 0 minutes 0.310 seconds) .. _sphx_glr_download_11_demos_python_packages_matplotlib_demo_surface3d.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: demo_surface3d.py ` .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: demo_surface3d.ipynb `