Re: R-alpha: plot f(x,y)

Ross Ihaka (ihaka@stat.auckland.ac.nz)
Wed, 31 Jul 1996 12:00:36 +1200


Date: Wed, 31 Jul 1996 12:00:36 +1200
From: Ross Ihaka <ihaka@stat.auckland.ac.nz>
Message-Id: <199607310000.MAA04839@stat.auckland.ac.nz>
To: Peter Dalgaard BSA <pd@kubism.ku.dk>
Subject: Re: R-alpha: plot f(x,y)
In-Reply-To: <199607302244.AAA04536@bush.kubism.ku.dk>
 <199607302244.AAA04536@bush.kubism.ku.dk>

Peter Dalgaard writes:
 > In article <Pine.OSF.3.91.960730161024.8675A-100000@io.uwinnipeg.ca> Bill Simpson <wsimpson@uwinnipeg.ca> writes:
 > 
 >    In Splus one can plot f(x,y) with 
 >    image
 >    persp
 >    contour
 > 
 >    These doe plans to make one of these available?
 > Er? Say what?
 > 
 >    Failing that, does anyone have code allowing one to do these things in R?
 > 
 > Hm. I think gnuplot (beta version?) can already do some of that. I
 > wonder what its authors would say to a little - um -
 > cross-fertilization?

I looked at gnuplot, but it has restrictions like not handling NAs.
It is also not written in a very modular fashion so it would be
relatively hard to just extract just the necessary algroithms.

contour (the most difficult) is already done and in the latest release
- although I am still looking at methods for labelling the contours.
Persp is pretty easy and image is essentially trivial.  It all really
just comes down to having the time to do the job.

You could write an interpreted persp as follows.  Run all the facets
through a perspective transformation and then sort by depth.  Start
at the back and draw each facet by filling with a solid color to
erase whatever's behind and then draw the boundary.  Axes are rather
harder.

At present I'm pretending to be a real statistician and am doing some
demand forecasting for the local airline so they can make decisions on
aircraft leasing.  There's some serious $$ at stake so that gets
priority.
	Ross
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
r-testers mailing list -- To (un)subscribe, send
subscribe	or	unsubscribe
(in the "body", not the subject !)  To: r-testers-request@stat.math.ethz.ch
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-