If you want to handle a generic case, best thing is to create an R package. It is much easier to manage that using source(), if you have lots of different functionality and data files. Also look at ?system.file.
On Sat, Nov 24, 2012 at 7:49 AM, Jeff Newmiller <jdnew...@dcn.davis.ca.us> wrote: > It is straightforward to load function definitions into memory using the > source() function. > --------------------------------------------------------------------------- > Jeff Newmiller The ..... ..... Go Live... > DCN:<jdnew...@dcn.davis.ca.us> Basics: ##.#. ##.#. Live Go... > Live: OO#.. Dead: OO#.. Playing > Research Engineer (Solar/Batteries O.O#. #.O#. with > /Software/Embedded Controllers) .OO#. .OO#. rocks...1k > --------------------------------------------------------------------------- > Sent from my phone. Please excuse my brevity. > > sheenmaria <sheenmar...@gmail.com> wrote: > >>How to call a function from another r file ? >>Anyone can help me . >> >>Having a function named like fun1 which is saved in r file file1.r >>and i have another r file like file2.r, and i need to call the fun1 >>(which >>is in file1) within file2. >> >>Thank you >> >> >> >> >>-- >>View this message in context: >>http://r.789695.n4.nabble.com/function-call-from-another-r-file-tp4650627.html >>Sent from the R help mailing list archive at Nabble.com. >> >>______________________________________________ >>R-help@r-project.org 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. > > ______________________________________________ > R-help@r-project.org 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. ______________________________________________ R-help@r-project.org 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.