The full graphics programming language of
Mathematica provides many tools to show data in 3D. The ability to plot points, surfaces, and contours, combined with the interpolation power of
Mathematica, results in accurate 3D visualizations. There are also many ways to customize and interact with these 3D plots that help you to better understand your data.
First, create datasets to plot in 3D.
ExampleData is used to get the second set of data:
Use
ListPointPlot3D to plot the list of 3D points given by
data1:
| Out[2]= |  |
Use the
ColorFunction option with
ListPointPlot3D to color the plot with a predefined gradient:
| Out[3]= |  |
Use
ListPlot3D to generate a 3D surface plot from
data1:
| Out[4]= |  |
Specifying mesh properties is one way to customize these plots. This example uses
Mesh,
MeshFunctions,
MeshShading, and
MeshStyle with
ListPlot3D:
| Out[5]= |  |
Use
ListSurfacePlot3D to generate 3D surfaces from either set of data:
| Out[6]= |  |
| Out[7]= |  |
Use
ListSurfacePlot3D to construct a 3D surface from
data1, with restrictions on the number of points used in interpolation and the size of the mesh:
| Out[8]= |  |
Use other mesh options available for
ListSurfacePlot3D:
| Out[9]= |  |
Mesh options are also available for
ListContourPlot3D:
| Out[10]= |  |
Mathematica also allows you to plot vector data in 3D.
Use
ListVectorPlot3D to visualize vector data:
| Out[11]= |  |
Plots in 3D integrate well with other
Mathematica functions.
Use
Manipulate with
ListSurfacePlot3D to view an interactive 3D plot where you can adjust the size and color of the mesh. Using the mouse, you can rotate, zoom, and pan any of these plots just as you would any other 3D graphic. You must evaluate this example to see the result: