[Rd] R_PROFILE on Windows

From: Fernando Henrique Ferraz P. da Rosa <academic_at_feferraz.net>
Date: Tue 13 Dec 2005 - 18:16:20 GMT

  Dear R-devel,

        There seems to be a bug in the Startup section, regarding the R_PROFILE environment variable in Windows. If not a bug in the Startup itself, perhaps a bug in the documentation.

        According to ?Startup:

       Then R searches for the site-wide startup profile unless the
       command line option '--no-site-file' was given.  The name of this
       file is taken from the value of the 'R_PROFILE' environment
       variable. If this variable is unset, the default is
        On Windows XP, I created a batch file with the following lines:

        SET R_PROFILE="C:\fernando\R.profile"
        On c:\fernando\R.profile I had:


        Running the batch file I created I get, in R:

> options()$foo
R_PROFILE "\"c:\\fernando\\R.profile\"" I've tried using slashes instead of backslashes
(fernando/R.profile), double blackslashes (fernando\\R.profile) but it seems there's no way to make it work.

        The only way I could manage to have R read the profile was renaming R.profile to .Rprofile and starting R on the directory the .Rprofile was located.

        Is this really the intended behaviour? If so, what's the correct way to specify the R_PROFILE variable and have R use it on Windows?

        Ps: I've tested it on R 2.2.0 and on r-devel r36675, on Windows XP SP2. Sorry if this is a non-bug. I'm a poor linux user trying to survive on Windows, so I might have overloooked something.

        Thank you,

"Though this be randomness, yet there is structure in't."
                                           Rosa, F.H.F.P

Instituto de Matemática e Estatística
Universidade de São Paulo
Fernando Henrique Ferraz P. da Rosa

R-devel@r-project.org mailing list
Received on Wed Dec 14 07:34:49 2005

This archive was generated by hypermail 2.1.8 : Mon 20 Feb 2006 - 03:21:34 GMT