How to properly document S4 class slots using Roxygen2?

后端 未结 3 1708
予麋鹿
予麋鹿 2020-12-04 07:04

For documenting classes with roxygen(2), specifying a title and description/details appears to be the same as for functions, methods, data, etc. However, slots and inheritan

3条回答
  •  无人及你
    2020-12-04 07:47

    roxygen2 v4.1+ and Hadley's latest doc for doing this:

    http://r-pkgs.had.co.nz/man.html#man-classes

    I have not tried it yet for RC, but it works for me for S4 now.

    Previously

    It looks like S4 class slots are fully supported under Roxygen2 version 3.0+:

    http://blog.rstudio.org/2013/12/09/roxygen2-3-0-0/

    "document your S4 classes, S4 methods and RC classes with roxygen2 – you can safely remove workarounds that used @alias and @usage, and simply rely on roxygen2 to do the right thing."

提交回复
热议问题