Re: [Rd] format: different S4 behavior in a package

2010-06-23 Thread Daniel Murphy
Thank you, Martin. That worked. And fyi 'export(format)' alone was not sufficient. Best, Dan On Wed, Jun 23, 2010 at 5:15 AM, Martin Morgan wrote: > On 06/23/2010 12:16 AM, Daniel Murphy wrote: > > R-Devel-ers: > > > > I have an S4 method that simply formats an object: > > > > setGeneric("format

Re: [Rd] format: different S4 behavior in a package

2010-06-23 Thread Martin Morgan
On 06/23/2010 12:16 AM, Daniel Murphy wrote: > R-Devel-ers: > > I have an S4 method that simply formats an object: > > setGeneric("formatMe", function(x) standardGeneric("formatMe")) > setMethod("formatMe", "ANY", function(x) format(x)) > > If I issue the above in an R session, then define an S4

Re: [Rd] format: different S4 behavior in a package

2010-06-23 Thread Uwe Ligges
There is not a single definition of formatMe() in your message, therefore nothing works for me, not even the very first version... Best, Uwe Ligges On 23.06.2010 09:16, Daniel Murphy wrote: R-Devel-ers: I have an S4 method that simply formats an object: setGeneric("formatMe", function(x) s

[Rd] format: different S4 behavior in a package

2010-06-23 Thread Daniel Murphy
R-Devel-ers: I have an S4 method that simply formats an object: setGeneric("formatMe", function(x) standardGeneric("formatMe")) setMethod("formatMe", "ANY", function(x) format(x)) If I issue the above in an R session, then define an S4 class with its own format method, I get the desired result: