[Rd] install.packages with R 2.9.1 under Vista?

spencerg spencer.graves at prodsyse.com
Tue Jun 30 16:10:10 CEST 2009


      What do I need to do to get "install.packages" to work properly 
for me in R 2.9.1 under Vista? 


      Currently, install.packages in Rgui 2.9.1 by default goes to 
"C:\\Users\\sgraves\\Documents/R/win-library/2.9".  This is a problem 
for me, because R running under Emacs does not currently look there. 


      I made the mistake last night of first installing R 2.9.1 in the 
default "C:\Program Files".  When I found that packages I installed 
using Rgui could not be found from within Emacs, I uninstalled R from 
"C:\Program Files" and reinstalled it under "C:\Users\sgraves\R" 
alongside R 2.9.0, which has allowed "install.packages" from Rgui to be 
accessed from R under Emacs. 


      I've traced the problem to the different behavior of ".libPaths()": 


*** Rgui: 
.libPaths()
[1] "C:\\Users\\sgraves\\Documents/R/win-library/2.9"
[2] "C:/Users/sgraves/R/R-2.9.1/library"  


*** R under Emacs: 
 > .libPaths()
[1] "c:/Users/sgraves/R/R-2.9.1/library"


      What do you suggest? 
      Thanks,
      Spencer



More information about the R-devel mailing list