From d.scott at auckland.ac.nz  Fri Dec 11 01:52:21 2009
From: d.scott at auckland.ac.nz (David Scott)
Date: Fri, 11 Dec 2009 13:52:21 +1300
Subject: [Rd] How to organized code in the R/ directory of a package?
In-Reply-To: <4B2174B9.1050807@openanalytics.be>
References: <366c6f340912101356j1be51766lba30bc00de72e52f@mail.gmail.com>
	<4B2174B9.1050807@openanalytics.be>
Message-ID: <4B2197C5.9030305@auckland.ac.nz>

Tobias Verbeke wrote:
> Peng Yu wrote:
>> I'm making a package, Current, I put all R files in the R/ directory
>> in the package (without using subdirectory). This will become a
>> problem when there are many files in the directory. I'm wondering how
>> to use subdirectories in R/?
> 
> The standard solution is (I would think) to organize the code
> such that functions belonging together are grouped in one file.
> 

That is what I try to do. My rule is that functions which are documented 
in the same .Rd file are also in the same .R file. Might be more 
sensible for some packages than for others.

David

_________________________________________________________________
David Scott	Department of Statistics
		The University of Auckland, PB 92019
		Auckland 1142,    NEW ZEALAND
Phone: +64 9 923 5055, or +64 9 373 7599 ext 85055
Email:	d.scott at auckland.ac.nz,  Fax: +64 9 373 7018

Director of Consulting, Department of Statistics



[Rd] How to organized code in the R/ directory of a package?
David Scott