R sourcelibrary(rgl)x2=rnorm(500,3,2) y2=rnorm(500,5,1.5) z2=rnorm(500,16,18) par3d(windowRect=c(100,100,800,800)) plot3d(x2,y2,z2,col=4,xlim=c(-10,20),ylim=c(-10,20),zlim=c(-10,50),pch=120) f = function(x, y) (x^2+y^2)/8-3*x x=seq(-10,20,length=100) y=seq(-10,20,length=100) z=outer(x,y,f) rgl.bg(color="lightgreen") jcol = colorRampPalette(c("white", "red","green","navy","yellow","lightcyan","magenta","violet","pink")) persp3d(x, y, z,col=jcol(100)) |
You must enable Javascript to view this page properly. Drag mouse to rotate model. Use mouse wheel or middle button to zoom it. Object written from rgl 0.97.0 by writeWebGL. |