From r.hankin at noc.soton.ac.uk  Wed Aug 31 09:09:15 2005
From: r.hankin at noc.soton.ac.uk (Robin Hankin)
Date: Wed, 31 Aug 2005 08:09:15 +0100
Subject: [Rd] generic function argument list problem
Message-ID: <4EC54477-49E9-4F03-8151-5339D493895B@soc.soton.ac.uk>

Hi

it says in R-exts that


     A method must have all the arguments of the generic,  
including ... if the generic does.
     A method must have arguments in exactly the same order as the  
generic.
     A method should use the same defaults as the generic.


So, how come the arguments for rep() are (x, times, ...) and the  
arguments
for rep.default() are  (x, times, length.out, each, ...) ?  Shouldn't  
these be the same?


I am writing a rep() method for objects with class "octonion", and
my function rep.octonion() has argument list (x, times, length.out,  
each, ...)
just like rep.default(),   but  R CMD check complains about it, pointing
out that rep() and rep.octonion() have different arguments.

What do I have to do to my rep.octonion() function to make my package
  pass R CMD check without warning?


--
Robin Hankin
Uncertainty Analyst
National Oceanography Centre, Southampton
European Way, Southampton SO14 3ZH, UK
  tel  023-8059-7743



[Rd] generic function argument list problem
Robin Hankin