Volume Visualization

Visualize Data Slices

Explore a 3D function by plotting its values as a density on slices through space.

In[1]:=
Click for copyable input
data = Table[ Sin[x]^2 + Cos[y] + Sin[z], {z, -2, 2}, {y, -2, 2}, {x, -2, 2, 0.25}];
In[2]:=
Click for copyable input
ListSliceDensityPlot3D[ data, ImageSize -> {540, 405}, ColorFunction -> "Rainbow"]
Out[2]=

Plot it using discrete contours instead.

In[3]:=
Click for copyable input
ListSliceContourPlot3D[ data, ImageSize -> {540, 405}, ColorFunction -> "Rainbow"]
Out[3]=

Related Examples

de es fr ja ko pt-br ru zh