[R] .Internal(filledcontour()) - ancient history or just plain wrong?

Prof Brian Ripley ripley at stats.ox.ac.uk
Sat Jun 14 11:18:46 CEST 2014

On 14/06/2014 10:04, Raphael Päbst wrote:
> Hello everyone!
> In my ongoing odyssey through badly dokumented and sparingly commented
> R-code, I've come across something that baffles me.
> The following line of code
> .Internal(filledcontour(as.double(x), as.double(y), z,
> as.double(levels), col = col))
>   not surprisingly results in an error, telling me that there is no
> such function as filledcontour().

But that passes a call to .Internal: it does not say what you say it 
does.  I suspect you saw

   there is no .Internal function 'filledcontour'

which is quite a different matter.

> The code this comes from has been written for an older version of R,
> probably 2.5.x so I was wondering, if the error results from me using
> a current version (3.1.0) or if the author wanted to use
> filled.contour() and forgot the '.'.
> Would that in fact help or was there something called filledcontour()
> that has changed into something else nowadays?

It has.  But it was never in the API, so should never have been used in 
user code and was never documented in R itself.

You should be able to rewrite this using .filled.contour in package 
graphics: it might be a drop-in replacement.

> I've tried to contact the author, but he hasn't used R for at least
> five years and hasn't replied so far, so I'm hoping soeone here can
> give me a hint to the solution of this problem.
> Many thanks in advance!
> Raphael

Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

More information about the R-help mailing list