On Tue, Nov 24, 2009 at 10:02 AM, Fredrik Johansson <fredj...@gmail.com> wrote: > I have an issue when making a wireframe plot. I can't find any way to > change the number of ticks on the labels. I try to set it in the code > below with z.ticks=1, but that doesn't work. Is there anything that > works? (Note. I need to use wireframe. persp is out of the question > since I want mathematics in the axis labels). > > Here is some sample code: > > library(lattice) > x <- as.matrix(seq(0,pi,0.1)) > z <- sin(x) %*% t(sin(x)) > dim(z) <- NULL > xy <- expand.grid(x,x) > w <- data.frame(xy[,1],z,xy[,2]) > colnames(w) <- c('x','z','y') > wireframe(z~x*y, data = w, > xlab = expression(italic(x)), > ylab = expression(italic(y)), > zlab = expression(sin(italic(x*y))), > screen = list(z=25,x=-60), > scales = list(z.ticks=1, arrows=FALSE))
'tick.number' should work (as described in ?xyplot). If you want it for z only, use scales = list( arrows=FALSE, z = list(tick.number=1))) etc. -Deepayan ______________________________________________ R-help@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.