Hi there, Anyone has an idea how to put those two sets of code together so that I can get a 3-dimensional picture that includes points instead of 2 separate pictures which doesnt make that much sense at the end.
#Let's say that these are the data we would like to plot: A<-c(62,84,53) B<-c(64,82,55) C<-c(56,74,41) D<-c(46,68,38) E<-c(71,98,72) data<-rbind(A,B,C,D,E) colnames(data)<-c("One", "Two","Three") library(rgl) # First set of code which gives 3-D picture rgl.lines(c(0,1.2),c(0,0),c(0,0)) rgl.lines(c(0,0),c(0,1.2),c(0,0)) rgl.lines(c(0,0),c(0,0),c(0,1.2)) rgl.lines(c(0,0),c(0,1),c(1,0),size=2) rgl.lines(c(0,1),c(1,0),c(0,0),size=2) rgl.lines(c(0,1),c(0,0),c(1,0),size=2) # Second set of code which gives only points that should actually be on the previous picture rgl.points(data[,3],data[,1],data[,2], size=5) rgl.texts(data[,3],data[,1],data[,2], text=rownames(data)) Looking forward to hear from you. Regards, Ana [[alternative HTML version deleted]] ______________________________________________ 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.