[R] Path to R script

Shi, Tao shidaxia at yahoo.com
Wed May 12 22:19:47 CEST 2010


Don't quite understand your question, but it looks like a more IT issue to me.  I guess you store your R scripts in a central location (e.g. a server) and everybody call them from their own workstation, right?  Or you can always bundle your R scripts into a package and distribute it around your group.

...Tao




----- Original Message ----
> From: Johannes W. Dietrich <j.w.dietrich at medizinische-kybernetik.de>
> To: r-help at r-project.org
> Sent: Wed, May 12, 2010 12:31:19 PM
> Subject: [R] Path to R script
> 
> There is certainly a trivial solution for my question, but I can't find the 
> answer in the documentation.

I need a platform independent method to 
> obtain the file path of the current R script.

My working group uses R on 
> several machines with different operating systems including Mac OS X, Windows 
> and Linux, and for obvious reasons the file hierarchies are very different. 
> Therefore, it would be useful to be able to address data files and external 
> procedures relative to the path of the script.

Thank you for any 
> suggestion,

J. W. D.
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
> -- -- -- -- -- -- -- -- -- --
-- Dr. Johannes W. Dietrich, M.D.
-- 
> Laboratory XU 44, Endocrine Research
-- Medical Hospital I, Bergmannsheil 
> University Hospitals
-- Ruhr University of Bochum
-- 
> Buerkle-de-la-Camp-Platz 1, D-44789 Bochum, NRW, Germany
-- Phone: 
> +49:234:302-6400, Fax: +49:234:302-6403
-- eMail: "
> ymailto="mailto:j.w.dietrich at medical-cybernetics.de" 
> href="mailto:j.w.dietrich at medical-cybernetics.de">j.w.dietrich at medical-cybernetics.de"
-- 
> WWW: http://medical-cybernetics.de
-- WWW: http://www.bergmannsheil.de
-- 
> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
> --

______________________________________________

> ymailto="mailto:R-help at r-project.org" 
> href="mailto:R-help at r-project.org">R-help at r-project.org mailing list

> href="https://stat.ethz.ch/mailman/listinfo/r-help" target=_blank 
> >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.



More information about the R-help mailing list