[Rd] promptClass("numeric")

Wolski wolski at molgen.mpg.de
Mon Aug 16 16:43:56 CEST 2004


Hi!

As I said its not really a Problem. Its just an inconsistency which need is not apparent to me.

You can alternatively use promptClass or promptMethods to document methods.
promptClass always generates a section:

>>>>\section{Methods}{
>>>>   \describe{
>>>>     \item{coerce}{\code{signature(from = "ANY", to = "numeric")}: ...
>>>> } }
>>>> }

So you can use promptClass to provide a short description to your methods.

I would use promptMethods if the methods are elaborated (like a the plotting methods in package lattice) and I would like to to provide intensive and extensive explanation with examples.

But in case if my method "foo" which is so simple (it just prints "foo") I would like to use promptClass.


Yours

Eryk.


*********** REPLY SEPARATOR  ***********

On 8/16/2004 at 9:27 AM Deepayan Sarkar wrote:

>>>On Monday 16 August 2004 08:54, Wolski wrote:
>>>> Hi!
>>>>
>>>> Have written some functions with signature "numeric".
>>>>
>>>> eg.
>>>> setGeneric("foo",
>>>>  function(object,...)
>>>>                standardGeneric("foo"))
>>>> setMethod("foo",signature(object="numeric"),def = ....
>>>>
>>>> To generate the Rd file sceleton i use
>>>>
>>>> > promtClass("numeric")
>>>>
>>>> A shell of class documentation has been written to the
>>>> file 'numeric-class.Rd'.
>>>>
>>>>
>>>> but the file does contains just.
>>>>
>>>> \section{Methods}{
>>>>   \describe{
>>>>     \item{coerce}{\code{signature(from = "ANY", to = "numeric")}: ...
>>>> } }
>>>> }
>>>>
>>>> Were is my method "foo"?
>>>
>>>Why do you expect it to be there? If you want documentation for method 
>>>definitions of foo, use promptMethods("foo"); this is indicated 
>>>in ?promptClass:
>>>
>>>See Also:
>>>
>>>     'prompt' for documentation of functions, 'promptMethods' for
>>>     documentation of method definitions.
>>>
>>>Hth,
>>>
>>>Deepayan



Dipl. bio-chem. Eryk Witold Wolski    @    MPI-Moleculare Genetic   
Ihnestrasse 63-73 14195 Berlin       'v'    
tel: 0049-30-83875219               /   \    
mail: wolski at molgen.mpg.de        ---W-W----    http://www.molgen.mpg.de/~wolski



More information about the R-devel mailing list