Skip to content
Prev 155420 / 398513 Next

R_USER - in which file should I include it?

Hello

I am not sure whether R starts from the same dir.  For instance:

a) if I double-click on R-2.7.2 icon and then issue the command getwd(), the
result is:
[1] "C:/Users/eduardo/Documents"

b) If R starts from within Tinn-R, the result is:

getwd()
[1] "C:/Program Files/R/R-2/bin"

I want that no matter which calling R method I am using if I issue the
command getwd() (first command) the result is:

"C:/Users/eduardo/Documents/R"


Moreover all new packages go to "C:/Users/eduardo/Documents/R/win-library"


Thanks 

Ed

-----Original Message-----
From: Gabor Grothendieck [mailto:ggrothendieck at gmail.com] 
Sent: Monday, September 08, 2008 8:57 PM
To: Eduardo M. A. M.Mendes
Cc: r-help at r-project.org
Subject: Re: [R] R_USER - in which file should I include it?

Could you explain more clearly what you mean by "the same"?
Do you mean that each time you click on R 2.7.2 icon on your
desktop that running this from the R console:

getwd()

is the same directory on each startup?  Isn't that already the case?
I don't think you need to set any environment variables at all.  If
you don't set
any environment variables then what specifically is happening that
you don't want to happen?

On Mon, Sep 8, 2008 at 7:10 PM, Eduardo M. A. M.Mendes
<emammendes at gmail.com> wrote:
http://www.R-project.org/posting-guide.html