3

I updated R-Studio to the latest version (Version 0.98.953). When starting R-Studio I get the following in the console:

Error installing package: "\\psf\Home\Documents"
CMD.EXE wurde mit dem oben angegebenen Pfad als aktuellem Verzeichnis gestartet.
UNC-Pfade werden nicht unterst�tzt.
Stattdessen wird das Windows-Verzeichnis als aktuelles Verzeichnis gesetzt.
CMD.Exe will be started with the path given above as the current directory
UNC-Path will not be supported
Instead the Windows directory will be set to the current directory
* installing *source* package 'rstudio' ...
** R
** inst
Warnung in file.create(to[okay]) :
  kann Datei '\psf/Home/Documents/R/win-library/3.0/rstudio/CITATION' nicht erzeugen.     Grund 'No such file or directory'
Warning in file.create(to[okay]) :
file \psf/Home/Documents/R/win-library/3.0/rstudio/CITATION'
cannot be created. Reason 'No such file or directory'
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded
ERROR: loading failed
* removing '\\psf/Home/Documents/R/win-library/3.0/rstudio'

Error installing package: "\\psf\Home\Documents"
CMD.EXE wurde mit dem oben angegebenen Pfad als aktuellem Verzeichnis gestartet.
UNC-Pfade werden nicht unterst�tzt.
Stattdessen wird das Windows-Verzeichnis als aktuelles Verzeichnis gesetzt.
CMD.Exe will be started with the path given above as the current directory
UNC-Path will not be supported
Instead the Windows directory will be set to the current directory
* installing *source* package 'manipulate' ...
** R
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded
ERROR: loading failed
* removing '\\psf/Home/Documents/R/win-library/3.0/manipulate'

Does anybody know what is wrong / what I have to do? I get the same error message on another PC with the same version of R-Studio.

Thank you in advance!

FreshF
  • 381
  • 1
  • 5
  • 13
  • 1
    this occurs when you open rstudio? what about r --vanilla? it looks to be building a package called manipulate when you start r I suppose. What is in your rprofile? Also, you might want to update R as well. The folder, at least, Rstudio is pointing to is an older version of r – rawr Jul 05 '14 at 16:01
  • Indeed, this occurs when I start RStudio. I updated R to the latest version which hasn't changed anything. What do you mean by r --vanilla? – FreshF Jul 06 '14 at 07:12
  • RStudio is a commercial product, try their support services. – Spacedman Jul 06 '14 at 08:03
  • This problem also happens when Mac users install Windows OS using Parallels. The answered question does work pretty much easy there. – Espanta Apr 11 '15 at 14:43

6 Answers6

2

RStudio installs the packages manipulate and rstudio your library when it starts up, if it detects that those packages are missing. The packages support various internal RStudio tools (for instance, manipulate supplies the plot manipulation widgets). It looks like it's having trouble doing this because your user library is on a UNC network path (\\psf). Try the following:

  1. Create a folder on the local disk in a directory you have write access to
  2. Add that folder to the R library path list (see here for details)
  3. Restart RStudio

RStudio should install the packages to your new writeable library.

Community
  • 1
  • 1
Jonathan
  • 8,497
  • 41
  • 35
  • 2
    You are indeed right. .libPaths() shows that the first [1] is set to a UNC network path. Despite creating a new folder and adding it to .libPaths() R Studio is still trying to use the first path. Any idea how I can CHANGE the first path permanently? – FreshF Jul 08 '14 at 09:01
1

I had pretty much the same issue after updating to 0.98.953. The solution I came up with deals with the same issue that Jonathan referred to in his answer, but isn't as fussy as creating a new R folder and adding it to the R library path list.

Let's assume that \\psf\Home\Documents refers to the same location as C:\Users\yourusername\Documents.

Open your .Renviron file (if you have one; if you don't, create an empty text file named .Renviron in your Documents folder—probably something like C:\Users\yourusername\Documents) and add the following (adjusting the paths as necessary):

HOME="C:/Users/yourusername/Documents"
R_LIBS_USER="C:/Users/yourusername/Documents/R/win-library/3.0"
R_USER="C:/Users/yourusername/Documents"

Make sure to use regular slashes (/) instead of backslashes (") in the paths!

After saving your changes to .Renviron, you should no longer have the error when you start RStudio.

I think it is probably unnecessary to add the HOME= line to your .Renviron file, but I did it just in case.

Community
  • 1
  • 1
Firefeather
  • 336
  • 1
  • 2
  • 12
  • tks, I used `R_LIBS_USER="C:/Apps/RStudio/R/library"` and i did not get the error. in this directory there is a `manipulate` and `rstudio` directory – HattrickNZ Nov 05 '14 at 01:20
1

None of the proposals where ok for me, the most i have obtained is

first manually install manipulate and rstudio packages in my personal library

second change name of the original folder in packages directory that means total functionality of the package.

Then I get another error as the procedure to install is unsuccesful (package not found as has been renamed).

Does any body know Where is the order to install them? if it can be corrected the message will probably dissappear

I guess that there is some problem derived from a Documents/R/win-library/3.1 y and R/R-3.1.2/library that invites rstudio to reject the package due to presumption of obsolete versions

Cheers

pedro
  • 11
  • 1
0

I am running Rstudio in windows 8.1 via Parallels Desktop 10 for Mac

in my case "\psf" is my Z: drive

So I made the ".Renviron." file in Z:\Documents (remember the last ".") else you will get an error message.

The content in the ".Renviron." file was:

HOME="Z:\Documents"

R_LIBS_USER="Z:\Documents\R\win-library\3.1"

R_USER="Z:\Documents"

You might have to change "3.1" within R_LIBS_USER="Z:\Documents\R\win-library\3.1" depending on the version you are

0

I solved this issue by adding

.libPaths("C:\\a\\path\\i\\can\\write\\to\\R-libs")

in my .Rprofile

(check ?Startup if you need guidance regarding .Rprofile)

vertikalist
  • 607
  • 6
  • 5
0

As Jonathan said:

RStudio installs the packages manipulate and rstudio [to] your library when it starts up, if it detects that those packages are missing.

To resolve the issue navigate to C:\Program Files\RStudio\R\modules\SessionPackages.R and comment out the two lines

#updateIfNecessary("rstudio")
#updateIfNecessary("manipulate")

You will no longer have the startup error but make sure the packages ARE kept up to date.

Best

steinbock
  • 726
  • 1
  • 12
  • 25