Keywords - Function groups - @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Library: graphic
See also: grxline gryline grlinreg grlinreg2

Quantlet: grsurfacecol
Description: generates a surface plot from a 3-dimensional dataset, with different color-levels depending on z-axis.

Link:
Usage: gs = grsurfacecol(x, colors, nm)
Input:
x n x 3 matrix containing user-defined data determining a grid
colors nm x 1 Color vector
nm Number of color levels
Output:
gs composed graphical object

Note:

Example:
library("graphic")
x  = grid(#(-3,-3), #(0.2,0.2), #(31,31))
f  = exp(-0.5.*(x[,1]^2+x[,2]^2))./(2.*pi)
freecolor()
cl=grcolorscheme("color",10)
createcolor(cl)
gs = grsurfacecol(x~f,cl,9)
d  = createdisplay(1,1)
show(d, 1, 1, gs)

Result:
shows a surface plot with 9 color-levels using colorscheme "color"



Author: M. Benko, 20000122
(C) MD*TECH Method and Data Technologies, 05.02.2006