Hi,
I need some help either in how to configure variables for wireframe(), or some suggestions as to other graphics commands to use for plotting a 2-D manifold in 3-D space.

Here is an example I tried (in the hopes that it would plot a helical line) :

xsp<-matrix(c(cos(seq(0,80)/5)),9,9)
ysp<-matrix(c(sin(seq(0,80)/5)),9,9)
zsp<-matrix(c((seq(0,80)/20)),9,9)
wireframe(zsp~xsp*ysp)

The resulting plot looks vaguely like a helix, but not right. And if I change my variables' dimensions to c(3,27) it looks "better," but if the dims are c(1,81), nothing gets plotted.

So: is there a way to control which points are connected by lines in wireframe()? Or is there a more appropriate way to provide a plotting program with sets of coordinates in 3-space?

My primary goal is to be able to plot surfaces, not just a line as in my sample code. For example, I might expand the data above to represent points on a 'ribbon' helix.

Thanks for yr. help -- feel free to point me to help files for existing packages or plotting routines.

Carl

______________________________________________
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.

Reply via email to