[R-pkg-devel] documentation of generic '['
Berri, Stefano
sberri at illumina.com
Wed Mar 9 14:32:30 CET 2016
Thank you Joris and Duncan!
\alias{[, encore,ANY,ANY-method}
is all it is needed to fix the WARNING.
Now that it is fixed, I will try to follow your other suggestions and move the documentation outside the class documentation (probably with other accessors would make more sense) and add
S4method{generic}{signature_list}(argument_list)
cheers
Stefano
From: jorismeys at gmail.com [mailto:jorismeys at gmail.com] On Behalf Of Joris Meys
Sent: 09 March 2016 13:15
To: Berri, Stefano
Cc: r-package-devel at r-project.org
Subject: Re: [R-pkg-devel] documentation of generic '['
Hi Stefano,
did you try moving the method to a separate file already? I've noticed that documentation of classes and methods in the same .Rd file isn't very straightforward. You need a \usage{} section to document the method, and that's likely to cause trouble when used in a class document.
In any case, afaik you need a :
\S4method{generic}{signature_list}(argument_list)
in the usage section, and you have to refer to the method as
\alias{[, encore,ANY,ANY-method}
See https://cran.r-project.org/doc/manuals/R-exts.html#Documenting-S4-classes-and-methods
Cheers
Joris
More information about the R-package-devel
mailing list