[Rd] R CMD <custom>?
hb at biostat.ucsf.edu
Mon Nov 28 21:41:48 CET 2011
On Mon, Nov 28, 2011 at 12:19 PM, Hadley Wickham <hadley at rice.edu> wrote:
>> That does seem to mix up namespaces quite a bit.
> That was just a proposal - equally
> R CMD mypackage::mycommand
> could just run
> but then passing argument might get a bit confusing.
>> But what does it get you
>> that "Rscript -e" doesn't already give you? You can set up your package so
>> R CMD mypackage::mycommand
>> executes a function, using delayedAssign or some of the more exotic features
>> (like external pointers and finalizers).
> Because you have to specify the path to that package? R CMD roxygen2
> is much easier to type, remember and is portable, compared to
> ~/R/roxygen2/something.r. It also makes R CMD scripts extensible by
> packages in a consistent manner.
When people run R CMD build, R CMD INSTALL, R CMD check etc, they are
in a well defined working directory. It can be assumed that R CMD
roxygen2 will be executed in the same directory. As so as you enter
the R prompt, you cannot assume this working directory, and you have
to document/specify which directory the command should be executed on.
Because of this, I favor an 'R CMD roxygen2' solution.
My use case/wish is to be able to provide 'R CMD Rdoc' (similar to 'R
CMD roxygen2') and 'R CMD rsp' (similar to 'R CMD Sweave').
> Assistant Professor / Dobelman Family Junior Chair
> Department of Statistics / Rice University
> R-devel at r-project.org mailing list
More information about the R-devel