[R] Wireframe graph: black and white shading instead of color
David Afshartous
dafshartous at med.miami.edu
Thu Nov 29 20:52:54 CET 2007
All,
The code below produces a color 3D graph. I'd like to make it black and
white shading. I tried setting col.regions to FALSE but this just made it
completely white. I want the graph to look exactly as is, except black (or
grey) and white shading. Is this possible?
Cheers,
David
p.list = c(.01, .1, .25, .5, .75, .9)
cov.list = c(.2, .1, .05) ### leave out .01
X = rep(p.list, 3)
Y = rep(cov.list, 1, each=6)
Z = c(2475.000000, 225.000000, 75.000000, 25.000000, 8.333333,
2.777778, 9900.000000, 900.000000, 300.000000, 100.000000,
33.333333, 11.111111, 39600.000000, 3600.000000,
1200.000000, 400.000000, 133.333333, 44.44444)
lattice.options(default.theme = "col.whitebg")
wireframe(Z ~ X * Y, scales = list(arrows = FALSE),
bg = "white", drape = TRUE, shade = FALSE, colorkey = FALSE,
xlab = "p", ylab = "C.O.V.", zlab ="n")
More information about the R-help
mailing list