Re: [R] scripts with littler / subroutines

From: John Lawrence Aspden <news_at_aspden.com>
Date: Mon 08 Jan 2007 - 15:02:27 GMT

François Pinard wrote:

> [John Lawrence Aspden]
>

>>Another difficulty I'm having is creating a common function (foo, say) to
>>share between two scripts.

>
> In your previous message, you were telling us that you want to load from
> your home directory. You might put the common functions there, maybe?
>

I am doing at the moment, and using source to load them in. I'm worried about what happens when I come to distribute the code though.

After a couple of e-mails off-list (thanks Dirk!) it sounds as though the solution is to create a library for R with the common subroutines in, and then load that from the scripts.

Cheers, John.

-- 
Contractor in Cambridge UK -- http://www.aspden.com

______________________________________________
R-help@stat.math.ethz.ch 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.
Received on Tue Jan 09 02:44:08 2007

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Mon 08 Jan 2007 - 16:30:30 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.