Re: [R] Plotting 3d data?

From: Henrique Dallazuanna <wwwhsd_at_gmail.com>
Date: Mon, 16 Jun 2008 14:39:00 -0300

Try scatterplot3d function in the package with same name.

On Mon, Jun 16, 2008 at 2:32 PM, Wesley Tansey <tansey_at_vt.edu> wrote:

> Hi all!
>
>
>
> I'm very new to R, and I'm having trouble figuring out how to go from a
> file
> of points that I have to a 3d surface plot of the data. I typically have
> something like this:
>
>
>
> X Y Z
>
> 0.005 0.023 34.45
>
> 0.0035 0.63 28.48
>
> .
>
>
>
> I've tried looking at the persp and wireframe packages, and the rgl
> package,
> but I can't seem to figure out how to use any of them. I tried to take the
> rgl.surface3d example and use it for myself, and this is what I have so
> far:
>
>
>
> setwd(".")
>
>
>
> data <- read.csv("data.csv",header=T)
>
>
>
> x <- data$X
>
> y <- data$Y
>
> z <- data$Z
>
>
>
> open3d()
>
> surface3d(x, y, z)
>
>
>
> That gives me the following error:
>
>
>
> Error in rgl.surface(x = c(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, :
>
> y length != x rows * z cols
>
>
>
> I have no idea what it is trying to tell me there. Would anyone mind
> helping
> me out?
>
>
>
>
>
> Wesley
>
>
>
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> 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.
>

-- 
Henrique Dallazuanna
Curitiba-Paraná-Brasil
25° 25' 40" S 49° 16' 22" O

	[[alternative HTML version deleted]]


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

Received on Mon 16 Jun 2008 - 18:01:07 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Mon 16 Jun 2008 - 18:30:41 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive