search for: grid3d

Displaying 7 results from an estimated 7 matches for "grid3d".

2010 Nov 22
1
Plotting a cloud/fog of variable density in rgl
...try with increase precision. # create a set of random data points in 3D n = 50 data3D = data.frame(x = runif(n), y = runif(n), z = runif(n), v = rnorm(n)) # do 3d interpolation via kriging library("gstat") coordinates(data3D) = ~x+y+z range1D = seq(from = 0, to = 1, length = 10) grid3D = expand.grid(x = range1D, y = range1D, z = range1D) gridded(grid3D) = ~x+y+z res3D = krige(formula = v ~ 1, data3D, grid3D, model = vgm(1, "Exp", .2)) # convert the result to a data.frame d = as.data.frame(res3D) # compute transparency (proportional to the interpolated value) max...
2008 Jun 21
1
question on rgl.surface
I'd like to use rgl.surface (or some other function if more appropriate) to create a horizontal and vertical transparent grey slice (plane) running through both the x and y origins and extending across the z axis, i.e. the 3-d equivalent of the normal 2-d coordinate axes we are all familiar with. The examples for rgl.surface are a bit more complex than what I need and I am having trouble
2010 May 18
1
[RGL] Need help to modify current plot
Dear folks, I have created a plot on RGL device :   x = 1:6 y = seq(-12, 5, by=1) z = matrix(0, length(y), length(x)) z[13,3] = 1; z[13,4] = 1.011765 surface3d(x, y, t(z), col=rainbow(1000)) grid3d(c("x-", "y-", "z"))   Now I want to draw 2 lines along x=3 & x=4, over the surface (with different colour). Could somebody help me how to draw that?   Thanks, [[alternative HTML version deleted]]
2017 Oct 19
1
overlaying points and lines on a surface3d rgl plot with axes
Hi R users and experts, I am interested in learning more about the use of 3D plots. Specifically, I want to add points and lines to a surface plot. And get the axes and labels plotted also. Here is what I have tried with an example data set : library(rgl) vol2 <- 2*volcano # Exaggerate the relief library(reshape) mvol2 <- melt(vol2) str(mvol2) # First, persp and persp3d plots do not succeed
2009 Oct 28
2
Labelling individual points on 3D PCA scatterplot
Hi There, I'm attempting to plot 10 values on a three-dimensional PCA with text labels next to each point. While i have no trouble doing this on 2D plots using the 'text' or 'textxy' function, I cannot find a function to do this on a 3D plot. I am using princomp for my PCA: >PCA<-princomp(eucdata, cor=TRUE) >PCA$scores [,1:3] # the three principal components i
2008 Jan 26
2
scatterplot3d with categorical data
Dear users, I'm trying to produce a 3d bar plot but the x and y dimensions have categorical data -- so I only want 3 points on each axis. So I try: require(scatterplot3d) mymat<-data.frame( x=c(1,1,1,2,2,2,3,3,3), y=c(1,2,3,1,2,3,1,2,3), z=c(1,2,3,4,5,6,7,8,9)) scatterplot3d(mymat, type="h", lwd=5, pch=" ", xlab="xlabel",
2010 Nov 24
0
4. Rexcel (Luis Felipe Parra)-how to run a code from excel
...try with increase precision. # create a set of random data points in 3D n = 50 data3D = data.frame(x = runif(n), y = runif(n), z = runif(n), v = rnorm(n)) # do 3d interpolation via kriging library("gstat") coordinates(data3D) = ~x+y+z range1D = seq(from = 0, to = 1, length = 10) grid3D = expand.grid(x = range1D, y = range1D, z = range1D) gridded(grid3D) = ~x+y+z res3D = krige(formula = v ~ 1, data3D, grid3D, model = vgm(1, "Exp", .2)) # convert the result to a data.frame d = as.data.frame(res3D) # compute transparency (proportional to the interpolated value) max...