[R] 3d plots?

About this list Date view Thread view Subject view Author view

From: Jason Turner (jasont@indigoindustrial.co.nz)
Date: Mon 12 Feb 2001 - 22:50:31 EST


Message-ID: <20010213015030.A1994@camille.indigoindustrial.co.nz>

Hi all

I'm trying to create a three-dimensional wireframe-type plot,
much like the screenshot shown at
http://www.r-project.org/screenshots/volcano-persp.jpg

In my case, I'm trying to show a density estimate of
two-variable system, using the GenKern package. I've
used the image() and contour() to create a nice shaded plot,
but I've found a 3d plot is often easier for the audience
to absorb.

The session is simple enough; dfw is a data.frame of
two variables, pressure and flow.

> library(GenKern)
> attach(dfw)
> ks<- KernSur(pressure,flow)
#now, make the shaded contour plot.
> image(ks$xvals,ks$yvals,ks$zden,col=terrain.colors(100), axes=TRUE)
> contour(ks$xvals,ks$yvals,ks$zden,add=TRUE)

Any ideas from here?

Cheers

Jason

-- 
Indigo Industrial Controls Ltd.
64-21-343-545
jasont@indigoindustrial.co.nz
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


About this list Date view Thread view Subject view Author view

This archive was generated by hypermail 2b30 : Fri 22 Jun 2001 - 18:58:32 EST