2D Functions
Function Plot
Parametric Plot
Multiple Parametric Plot
Filled Plot
Multiple Filled Plot
Logarithmic Plot


2D Data Plots
Data Plot
Data Error Plot
Data Logarithmic Plot
Data Labeled Plot


Contour & Density Plots
Contour Plot
Density Plot
Level Curves


3D Functions
3D Function Plot
3D Parametric Plot
3D Multiple Parametric Plot
3D Vector Field
3D Gradient Field
Shadow 3D Function

3D Data Plots
Contour 3D Data Plot
Density 3D Data Plot


Special Plots
Vector Field
Bar Charts
Pie Chart
Zonotope Show


Links
About This Site
Citation & Credits
Sci.Vis. Tutorials
webComputing


Density 3D Data Plot

A density plot generated from an array of height values. It shows a rectangular plot that consists of a grid of smaller rectangles each being colored according to the value of the array.
array = {{z11, z12, ...., z1,n2}, .... {zn2,1, zn2,2, ...., zn1,n2}},     zij = z(xi, yj),    1 < = i < = n1,   1 < = j < = n2
Successive rows of the array are arranged up the page; successive columns across the page.


Enter a two dimentional list :   

" >



<%Mathlet MSPBlock[{$$list, $$frame, $$meshx0, $$meshx1, $$meshy0, $$meshy1, $$imageSize, $$mesh, $$shColor, $$meshstyle, $$plotLabel, $$fr1, $$fr2, $$fr3, $$fr4, $$rotateLabel, $$aspectRatio, $$xRangeBeg, $$xRangeEnd, $$yRangeBeg, $$yRangeEnd, $$zRangeBeg, $$zRangeEnd, $$rColor, $$gColor, $$bColor, $$rColorBackg, $$gColorBackg, $$bColorBackg}, result = ListDensityPlot[$$list, AspectRatio->If[$$aspectRatioFlag === "Specified", $$aspectRatio, MSPToExpression[$$aspectRatioFlag]], Mesh->$$mesh, ColorFunction ->$$shColor, Frame->$$frame, FrameLabel->{If[$$fr1 === Null, "", ToString[HoldForm[$$fr1]]], If[$$fr2 === Null, "", ToString[HoldForm[$$fr2]]], If[$$fr3 === Null, "", ToString[HoldForm[$$fr3]]], If[$$fr4 === Null, "", ToString[HoldForm[$$fr4]]]}, PlotLabel->If[$$plotLabel === Null, "", ToString[HoldForm[$$plotLabel]]], PlotRange->{If[$$xPlotRange === "Specified",{$$xRangeBeg,$$xRangeEnd}, MSPToExpression[$$xPlotRange]], If[$$yPlotRange === "Specified",{$$yRangeBeg,$$yRangeEnd}, MSPToExpression[$$yPlotRange]], If[$$zPlotRange ==="Specified", {$$zRangeBeg,$$zRangeEnd}, MSPToExpression[$$zPlotRange]]}, MeshRange->If[$$meshrange ==="Specified", {{$$meshx0,$$meshx1},{$$meshy0,$$meshy1}}, MSPToExpression[$$meshrange]], MeshStyle->$$meshstyle, RotateLabel->$$rotateLabel, DefaultColor->If[{$$rColor,$$gColor,$$bColor} =!= {"","",""}, RGBColor[$$rColor,$$gColor,$$bColor], Automatic], Background-> If[{$$rColorBackg,$$gColorBackg,$$bColorBackg} =!= {"","",""}, RGBColor[$$rColorBackg,$$gColorBackg,$$bColorBackg], Automatic], ImageSize-> If[NumberQ[$$imageSize],$$imageSize,Automatic] ]; If[Head[result] === DensityGraphics, MSPShow[result]] ] %>

Save as: 

With file name:   " > <%Mathlet MSPBlock[{$$fname, $$submitButton1}, c = If[$$fname === Null, "", ToString[$$fname]]; ftype = Switch[$$opt, "jpg", "JPEG", "tif", "TIFF", "eps", "EPSTIFF", "xbm", "XBitmap", "mps", "MPS", _ , $$opt]; If[Head[result] === DensityGraphics, MSPReturn[DisplayString[result, ftype], "image/"<>ftype , c<>"."<>$$opt] ] ] %>


Density Data Plot options

Mesh:   <%Mathlet MSPSetDefault[$$mesh, "True"]; %> > True   > False    whether to draw a mesh

Colored in:   <%Mathlet MSPSetDefault[$$shColor, "Automatic"] ;%> > Gray scale   > Color scale   whether to use colors for shading

Mesh Range:    This option sets the range of values in x and y. It makes sure that the axes are properly arranged.

<%Mathlet MSPSetDefault[$$meshrange, "Automatic"]%> > Automatic   > Specified for both :

Mesh range for x-axis:   from   " >   to   " >

Mesh range for y-axis:   from   " >   to   " >

Mesh style:  

General options

Plot range: (All - all points are included, Automatic - outlying points are dropped)

X:  <%Mathlet MSPSetDefault[$$xPlotRange, "Automatic"] %> > Automatic   > All   > Specified   " >  < = x < =  " >

Y:  <%Mathlet MSPSetDefault[$$yPlotRange, "Automatic"] %> > Automatic   > All   > Specified   " >  < = y < =  " >

Z:  <%Mathlet MSPSetDefault[$$zPlotRange, "Automatic"] %> > Automatic   > All   > Specified   " >  < = z < =  " >

<%Mathlet MSPSetDefault[$$frame, "True"] ;%> Frame:  > True   > False

Frame labels:

Frame label down:   " >  Frame label left:   " >

Frame label up:   " >  Frame label right:   " > 

<%Mathlet MSPSetDefault[$$rotateLabel, "True"] %> Rotate labels:  > True   > False   (whether to allow text in frame labels to be vertically positioned)

Plot label:   " >

<%Mathlet MSPSetDefault[$$aspectRatioFlag, "Automatic"] %> Aspect ratio :  > Default   > Automatic   > Specified :   " >
Setting the AspectRatio option changes the whole shape of your plot. AspectRatio gives the ratio of height to width.
Its default value is the inverse of the Golden Ratio - supposedly the most pleasing shape for a rectangle.
Automatic determines the shape of the display area from the original coordinate system.


Frame color (RGB color):  red part :  " >   green part :  " >   blue part :  " >
The values of the color parts must be between 0 and 1.

Background (RGB color):  red part :  " >   green part :  " >   blue part :  " >

Image size:   ">   specifies that the image should have a width of x printer's points

  
© 2004 webComputing,   Scientific Visualization