[R] Author at R

Achim Zeileis Achim.Zeileis at uibk.ac.at
Sun Feb 5 23:34:28 CET 2012

On Sun, 5 Feb 2012, Matyas Sustik wrote:

> Hi All,
> Could someone point me to an example on how to use Author at R in a package 

There is an introduction in the following report:

> Say with 2 authors: John Doe and Jane Doe, the latter is a maintainer 
> which could replace:
> Author: John Doe, Jane Doe
> Maintainer: Jane Doe

You can use

Authors at R: c(person(given = "John", family = "Doe", role = "aut"),
   person(given = "Jane", family = "Doe", role = c("aut", "cre"),
     email = "Jane.Doe at e-mail.org"))

If you omit the Author/Maintainer fields, then R CMD build will produce 
them automatically as

Author: John Doe [aut], Jane Doe [aut, cre]
Maintainer: Jane Doe <Jane.Doe at e-mail.org>


> "Both ?Author? and ?Maintainer? can be omitted (as from R 2.14.0) if a
> suitable ?Authors at R? is given. This field can be used to provide a
> refined, machine-readable description of the package ?authors? (in
> particular specifying their precise roles), via suitable R code. The
> roles can include ?"aut"? (author) for full authors, ?"cre"? (creator)
> for the package maintainer, and ?"ctb"? (contributor) for other
> contributors, among others. See ?person for more information. Note
> that no role is assumed by default. Auto-generated package citation
> information takes advantage of this specification; in R 2.14.0 or
> later, the ?Author? and ?Maintainer? fields are auto-generated from it
> if needed when building or installing."
> Yes, I also checked ?person but no example there either.  I am quite a
> newbie and preparing my first R package... Thanks!
> -Matyas
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

More information about the R-help mailing list