[R] writing R extension

Sarah Goslee sarah.goslee at gmail.com
Wed Dec 20 18:09:47 CET 2006


For a very simple library, you really only need chapter 1 of the manual
on writing R extensions, which even describes the "helper functions"
that take some of the work out of making a "proper" package.

If that's still too complex, you could also save your function to a file
and load it as needed with source(). That will give the user the
same effect.

source("/path/to/my/stuff/myfiles.R")

Since you didn't tell us OS or anything else about your system,
it's hard to be more specific.

Sarah

On 12/20/06, michele de meo <vbarstat at gmail.com> wrote:
> I'd like to develop a simple library in R in which to save my
> particular functions.
> I have read the manual on "Writing R Extensions" but it's too
> difficult. Someone could help me?
>
> I want only save my personal function (recorded in R-code, not in C) in
> "myLibrary" and I want to call it with:
>
>  >library (myLibrary).
>
> After this, the functions should be available directly in R.
>
> I know that it's possible to save functions in the workspace, but I
> need this functions in a library.
>


-- 
Sarah Goslee
http://www.stringpage.com
http://www.functionaldiversity.org



More information about the R-help mailing list