В Thu, 8 May 2025 19:39:40 +0000 (UTC) ravi via R-help <r-help@r-project.org> пишет:
> In windows, I add the following line: > .libPaths(c(“C:/Rownlib”,”C:/R/R-4.5.0/library”)) > in the file C:/R/R-4.5.0/etc/Rprofile.site > > I have my own list of packages in the Rownlib folder and the packages > that come with the R installation for the latest version in the > second folder. When upgrading to a new R version, I just change the > 2nd library location to that for the updated R version. This is not guaranteed to work, especially for (but not limited to) packages that compile source code and link to various interfaces inside R: https://stat.ethz.ch/pipermail/r-help/2025-April/480832.html This problem is more visible on Ubuntu than on Windows. On GNU/Linux systems, R packages will link to the third-party libraries you install from the GNU/Linux repositories. When you update your Ubuntu installation, the installed packages may stop working. > I noticed then that ubuntu has another file ~ etc/Renviron (this > seems to be absent on windows). This perhaps has priority over what > is in Rprofile.site. I see the following in Renviron: > R_LIBS_USER=${R_LIBS_USER:-'%U'} Don't edit the system-wide configuration files to change settings that are valid for your user only. Instead, set R_LIBS_USER=/home/rvi/Rownlib in /home/rvi/.Renviron and make sure that the directory exists. In addition to "R Installation and Administration" (section 6.2), these settings are documented in help(Startup) and help(.libPaths). -- Best regards, Ivan ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide https://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.