R packages/libraries [🇷 for BE/BA]

posted by d_labes  – Berlin, Germany, 2015-08-12 11:07 (3471 d 19:32 ago) – Posting: # 15240
Views: 17,564

Dear BE-proff, dear Helmut,

❝ It it getting really interesting :-D


❝ I have installed missed mvtnorm package and now R says:


Error in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]) : object 'vI' not found

Error: package or namespace load failed for ‘PowerTOST’


That all is very mysterious to me :confused:!
I always got packages including all dependencies. And they worked out of the box. How do you install packages? Via menu within Rgui.exe? Or via install.packages()? Any errors during installation?

After Goggling a while I think this link Number 7 may be a hint to the reason:
The user which you use to install packages must have write permissions to the location where the package will be saved on your drive(s). Usually this is "c:\Program Files\R\R-3.2.1\library\" if you haven't set it to other. And 'ordinary' users don't have write permissions there.

You may query the path by
.libPaths()
Then check if the directories PowerTOST and/or mvtnorm look like the other packages of the base install.

BTW: It may be a good idea to have the packages not in base installation separated. I have a directory "c:\Program Files\R\library\" for that :cool:.
To work with this setting you have to create under "c:\Program Files\R\R-3.2.1\etc\" a file named Renviron.site with the content
R_LIBS="C:/Program Files/R/library"
But beware also your write permissions in that location.

Hope this helps.

Regards,

Detlew

Complete thread:

UA Flag
Activity
 Admin contact
23,380 posts in 4,914 threads, 1,662 registered users;
28 visitors (0 registered, 28 guests [including 7 identified bots]).
Forum time: 05:39 CET (Europe/Vienna)

Skill is a function of chance.
It’s an intuitive best-use of chance situations.    Philip K. Dick

The Bioequivalence and Bioavailability Forum is hosted by
BEBAC Ing. Helmut Schütz
HTML5