[R] Saving functions
mpromber at psych.upenn.edu
Mon Sep 8 17:10:12 CEST 2008
On Monday, 08 September 2008, 15:46 (UTC+0100), Williams, Robin wrote:
> I have written a function in a text editor and saved it with an .R
> extension. It is saved in my working directory. How can I run it, do I
> need to use source?
Just to add to Jim's reply: if you want to have this function
available every time you use R, you could put it into your "Rprofile"
I'm using Linux, and for me this is just a text file saved in my home
directory "~/.Rprofile" (note the dot). Everything in there gets read
when I start R.
Not sure about other OSes. Maybe google "Rprofile".
Graduate student in Psychology
More information about the R-help