SETPLOTTYPE

Purpose:

Sets the plot type for a table of data.

Syntax:

SETPLOTTYPE(table, ptype)

table

-

Optional. A multi-column series. Defaults to the current Window.

ptype

-

An integer, the plot type:

0:

Series (line) plots

1:

Waterfall plot

2:

Contour map

3:

Density (image) plot

4:

Z Surface (3D plot)

5:

Image plot

6:

Chart (multiple line plots)

7:

Stripchart plot

Returns:

Nothing, sets the series plottype.

Example:

setplottype(W3, 2)

 

sets the graph in Window 3 to be a contour map.

Example:

W1: spline2(rand(10), 5);setplottype(4)

 

creates and displays a spline interpolated Z surface.

Example:

W1: gnorm(100,1);overlay(gnorm(100,1));setplottype(7)

 

creates a stripchart with two traces.

 

Example:

W1: spline2(rand(10), 5)

W2: w1;setplottype(2);turbo

W3: w1;setplottype(3);turbo

W4: w1;setplottype(4);turbo

 

image\setplottype1.png

 

W1 creates and displays a spline interpolated 61x61 random array as a set of lines.

 

W2 displays the data as a contour plot.

 

W3 displays the data as a density (image) plot

 

W4 displays the data as a surface plot.

Remarks:

Use SETPLOTTYPE, the menus, the Graphical Styles toolbar button, or the [F7] key to see different styles of a particular plot type. For example, a waterfall plot could be viewed as a surface, line, or point plot; a 3-D bar graph; or a table of values.

 

If the plot type of a Window has not been set, the series will be displayed in the type of the series. If the Window type has been set, the series will be displayed in the type of the Window. For example:

 

W1: spline2(rand(10), 3);setplottype(5)

a = spline2(rand(10), 3);setplottype(a, 2)

W1: a

W2: a

 

The plot type of W1 is set to image and all (multiple column) series placed in W1 will be displayed as an image. The variable a plots as an image in W1 even though the plot type was set to contour. However, because the plot type of W2 was not previously set, the series plots as a contour map.

 

Use CLEAR to remove the Window plot type.

 

clear(w1)

W1: a

 

The series is now displayed as a contour map.

 

Density, type 3, and image, type 5 are normally identical. A density plot maps each value of a multi-column series to a color. The result is normally converted into an image for display speed.

 

See SETPLOTSTYLE to set the plotting style for a single column series.

See Also:

CONTOUR

DENSITY

GETPLOTSTYLE

GETPLOTTYPE

ITEMTYPE

PLOT3D

SETHATCH

SETPLOTSTYLE

STRIPCHART

TABLEVIEW

WATERFALL