Date:2017-07-13 (last modified), 2006-02-20 (created)

Mayavi2 is a interactive program allowing elaborate 3D plots of scientific data in Python with scipy. It is the successor of MayaVi for 3D visualization.

||\<#80FF80> The information on this page is a bit old and outdated. You are invited to refer to the Mayavi2 user guide as a reference. For a quick introduction to scripting, see mlab. In recent versions of Mayavi2, the user guide can be accessed in the help menu, but the user guide for the latest version of Mayavi can also be found on line. ||

If you need more help, you are invited to ask questions on the Enthought-dev mailing list.

In [ ]:
#class right
## Snazzy graphics here...
# ![](files/../_static/items/attachments/MayaVi/mayavi2.png)

!Mayavi2 relies on [ VTK], and especially a python interface to it: [ TVTK].

A mayavi2 session.

MayaVi2 topics

!MayaVi2 can be used as an interactive program or not, as it will be presented here.

* For installation of !MayaVi2 in the enthought tool suite see theMayavi documentation

* Using !MayaVi2:

There are (at least) two ways to use !MayaVi2:

* [:Cookbook/MayaVi/RunningMayavi2: Running MayaVi2] on the command line.

* [:Cookbook/MayaVi/ScriptingMayavi2: Scripting MayaVi2] in Python.

* [:Cookbook/MayaVi/Examples: Scripting Examples] (all provided in !MayaVi2 svn tree):

* Using Contour Module (

* Using Glyph Module (

* Using Mayavi2 without GUI (

* A 3D array as numerical source (

* Using Streamline Module (

* Using !ImagePlaneWidget Module (

* Plotting a surface from a matrix ( See also [:Cookbook/MayaVi/Surf: Cookbook/MayaVi/Surf]

* [:Cookbook/MayaVi/Tips: Tips]: General tips for !MayaVi2 and around.


Using the mlab module from ipython

  • [:Cookbook/MayaVi/mlab: Mlab]: module allowing to drive VTK from Python to do 3D plots ala matlab.

  • [:Cookbook/MayaVi/tvtk: tvtk]: Traited VTK, including iVTK

'''Visualization of the (5,2,1) orbital of the H-atom using an iso-surface and a semi-transparant scalar cut plane.'''

Section author: ArndBaecker, Unknown[128], Unknown[6], FredericPetit, GaelVaroquaux, Christian Gagnon