How can I document the use of member functions of a reference class?
if I write an Rd file with a \usage block, how can I avoid WARNING
Functions/methods with usage in documentation object 'XmlDoc' but not in code: $ new
I expect the \usage block to allow me to write things like:
obj <- ClassName$new(par1, par2, ...) obj$method1(oth1, ...)
and then I will document the parameters in the \arguments block.
If I do, the R CMD check complains about
Assignments in \usage in documentation object 'ClassName':
and does not recognize methods as code objects, I need a document.
at the moment I am writing Rd files without the \usage block and writing the above code to the \examples block, but then I have nowhere to document the arguments, and thus check has very little to actually check. Since I am not satisfied with this, I am now asking the community about current general practice.
source share