[R] FW: changing the surface coloring (using lattice::wireframe)

Duncan Mackay dulcalma at bigpond.com
Fri Nov 22 23:16:20 CET 2013


Sending again as it did not make the list

-----Original Message-----
From: Duncan Mackay [mailto:dulcalma at bigpond.com] 
Sent: Friday, 22 November 2013 09:35
To: 'Smilyanov Georgi'
Subject: RE: [R] changing the surface coloring (using lattice::wireframe)

Hi Georgi

I have not used wireframe for years but I think it is similar to levelplot
as it is in that "group"

Depending on what you want try something like

              cuts     = 6,
              at       = c(0,1,5,15,25,35,55),
              col.regions =
c("#FFFFFF","#00FFFF","#A9E2FF","#8080FF","#0000FF","#FFD18F","#FF0000"),

which I just plucked from some scripts for levelplot that I had

I think that you need to read the documentation on it as well as drape may
come into play

Regards

Duncan

Duncan Mackay
Department of Agronomy and Soil Science
University of New England
Armidale NSW 2351
Email: home: mackay at northnet.com.au

-----Original Message-----
From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-project.org] On
Behalf Of Smilyanov Georgi
Sent: Friday, 22 November 2013 08:44
To: mailman, r-help
Subject: [R] changing the surface coloring (using lattice::wireframe)

Hi all,

I am using lattice::wireframe to create a surface. I need to change the
coloring so that it depends on the x or y variable (instead of on z). How
should this be done? The documentation says that the color is automatically
chosen to depend on the height (e.g. z).

Thanks!
Georgi
______________________________________________
R-help at r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list