本文介绍了延迟加载的R软件包的更新的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有几个使用R软件包的Unix服务器,该软件包安装在共享的R库文件夹中.软件包是从此共享文件夹中延迟加载的(默认设置).

I have several unix servers using a R package which is installed on a shared R library folder. The packages are lazy loaded (that's the default) from this shared folder.

现在我要更新软件包:

1)是否可以(而且很干净)在不关闭所有R实例的情况下做到这一点?

1) is it possible (and clean) to do that without closing all R instances?

2)更确切地说,我担心以下问题:
2)a)当我尝试安装已加载的软件包时,从用户界面收到警告:
2)b)来自 https://cran.r -project.org/doc/manuals/r-release/R-ints.html#Lazy-loading

2) More precisely, I am concerned about the following:
2)a) The warning I get from the user interface when I try to install a package that is already loaded:
2)b)From https://cran.r-project.org/doc/manuals/r-release/R-ints.html#Lazy-loading,

这是否意味着在对每个对象进行实际评估时,R实例将再次从库文件夹中读取(在这种情况下,这意味着我需要停用延迟加载,或者在更新程序包之前关闭所有R实例)

Does that mean that the R instance will read again from the library folder when doing the actual evaluation of each object (in which case that means I need to either deactivate the lazy loading, or close all R instances before updating the package)

3)还有另一种方法可以在始终运行脚本的服务器网络上维护R软件包,而不必使每个服务器都一个一个地脱机)

3) is there an alternative way to maintain R packages on a network of servers, that are running scripts all the time, without having to put each server offline one by one)

感谢您的输入

推荐答案

您问过

我可以肯定的是,这是到处都是的工作方式和完成方式.

and I can assure that yes, that it is how works and done everywhere.

您读错了.仅建议您重新启动R,以确保新程序包已加载,因为您无法将其插入正在运行的会话中.

you are reading it wrong. An R restart is simply recommended to ensure the new package is loaded as you cannot insert it into a running session.

进一步

从不需要只需使服务器脱机即可更新用户空间包.例如.例如,当我们每年两次升级整个Ubuntu版本时,我们甚至都不会脱机使用它们.

you never have to take a server off-line just to update a user-space package. E.g. we don't even take them off-line when we, say, upgrade the entire Ubuntu release twice a year.

这篇关于延迟加载的R软件包的更新的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-17 16:50