A 18:35 02/12/2003 +1300, Jason Turner a �crit:
Jeff D. Hamann wrote:

I've been developing a package and have been getting the following warning
when running the check command:
* checking S3 generic/method consistency ... WARNING
plot:
  function(x, ...)
plot.summaries:
  function(trees, sp)

I'm unclear; is "summaries" a class? If not, try naming the function plotSummaries, or some such thing (no dot ".")


Cheers

And if yes, you can rename the main argument inside the function:


plot.summaries <- function(x, sp, ...)
{
trees <- x
rm(x)
[...]
}

This allows you to keep the object name 'trees' inside the function.

Note that the "dot dot dot" (...) argument MUST be included in this case (use of the generic function plot). Have a look at the Writing R Extensions manual: there are very useful information there when writing a package.

Emmanuel Paradis



Jason
--
Indigo Industrial Controls Ltd.
http://www.indigoindustrial.co.nz
64-21-343-545
[EMAIL PROTECTED]

______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help

______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help

Reply via email to