[R] New package Rd2roxygen: Convert Rd to roxygen documentation

Yihui Xie xie at yihui.name
Wed Dec 1 16:04:49 CET 2010


A new package Rd2roxygen has been released on CRAN:
http://cran.r-project.org/package=Rd2roxygen (source package
available; binaries to come)

This package can be useful for developers who used to document their
functions in the raw Rd files but want to switch to roxygen now using
inline roxygen comments (e.g. me). The main functionality of this
package is to parse the Rd files under the ./pkg/man directory, and
update the R scripts under the ./pkg/R directory accordingly with
roxygen comments. It can deal with most of Rd tags correctly, but
there might be some trivial problems which need adjustment by hand.
This package will not make a backup of the source package first, so it
is recommended to back up the ./pkg/R directory before converting the
Rd files.

Package: Rd2roxygen
Type: Package
Title: Convert Rd to roxygen documentation
Version: 0.1-0
Date: 2010-11-30
Author at R: c(person("Hadley", "Wickham", email = "h.wickham at gmail.com",
    role = "aut"), person("Yihui", "Xie", email = "xie at yihui.name",
    role = c("aut", "cre")))
Author: Hadley Wickham and Yihui Xie
Maintainer: Yihui Xie <xie at yihui.name>
Depends: roxygen
Description: Functions to convert Rd to roxygen documentation. It can
    parse an Rd file to a list, create the roxygen documentation and
    update the original R script (e.g. the one containing the
    definition of the function) accordingly.
License: GPL
URL: https://github.com/yihui/Rd2roxygen
Collate: 'rd2roxygen.r' 'utils.r'

I asked the question in r-help a few days ago, and it seems some
developers are in the same situation as me. This is a solution to my
own question, hence Cc'ed to r-help as well.

Yihui Xie <xieyihui at gmail.com>
Phone: 515-294-2465 Web: http://yihui.name
Department of Statistics, Iowa State University
2215 Snedecor Hall, Ames, IA

More information about the R-help mailing list