Skip to content
Prev 301871 / 398503 Next

drawing a specific "plane" with scatterplot3d

On 12-07-31 2:54 PM, Andras Farkas wrote:
This is hard to do in scatterplot3d, because some points should be 
hidden and others shown in front of such a plane, but scatterplot3d has 
no way to do that.  You could do it using the rgl package; the commands 
there would be something like this (without the coloring you did in 
scatterplot3d):

plot3d(x,y,z)
planes3d(0,0,-1,6,col="red")
In rgl you would do it using

plot3d(x,y,z, col=ifelse(z < 6, "blue", "red"))

I think the same sort of thing works in scatterplot3d, but the arg name 
is color, not col.

Duncan Murdoch