track.copy(track)
track.copy()所属R语言包:track
Copy or move objects from one tracking db to another
从一个跟踪数据库的复制或移动对象
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Copy or move objects from one tracking db to another.
复制或移动到另一个从一个跟踪数据库的对象。
用法----------Usage----------
track.copy(from, to = 1, list = NULL, pattern = NULL, glob = NULL, delete = FALSE,
clobber = FALSE, skipExisting = FALSE, verbose = TRUE, do.untrackable = FALSE)
track.move(from, to = 1, list = NULL, pattern = NULL, glob = NULL, delete = TRUE,
clobber = FALSE, skipExisting = FALSE, verbose = TRUE, do.untrackable = FALSE)
参数----------Arguments----------
参数:from
The position on the search list of the source db. Can be numeric or the name as returned by search(). Can be a vector, in which case the action is repeated for each element of from.
的源数据库的搜索列表上的位置。可以是数字或名称,返回search()。可以是一个矢量,在这种情况下,该操作重复进行的每个元素from。
参数:to
The position on the search list of the destination db. Can be numeric or the name as returned by search().
目标DB的搜索列表上的位置。可以是数字或名称,返回search()。
参数:list
A character vector of the objects to copy or move
要复制或移动的字符向量的对象
参数:pattern
A regular expression specifying the objects to copy or move
正则表达式指定的对象复制或移动
参数:glob
A glob specifying the objects to copy or move
指定的对象复制或移动的glob
参数:delete
Should the objects in the source db be removed? The default is FALSE for track.copy and TRUE for track.move.
如果源数据库中的对象被删除?默认的是FALSEtrack.copyTRUE和track.move。
参数:clobber
Should the objects in the destination db be overwritten?
如果对象在目标数据库覆盖?
参数:skipExisting
If TRUE, skip objects where an object of the same name already exists in the destination db .
如果TRUE,跳过对象的对象相同的名称已经存在于目标DB。
参数:verbose
If TRUE, write out what is being done.
如果TRUE,写出正在做什么。
参数:do.untrackable
If TRUE, also copy untrackable objects. Not yet implemented.
如果TRUE,也无法追踪的对象复制。尚未实施。
Details
详细信息----------Details----------
track.copy copies objects by copying their underlying files from the source tracking db to the destination tracking db (behavior for untracked or untrackable objects is different – see below). It also copies the object summary (preserving modification times etc.) Objects are not loaded in R when copied, and if a copied object is cached in the source or destination db, the cached copy will be removed.
track.copy复制对象从源头上跟踪数据库的基础文件复制到目标跟踪数据库(不露痕迹的或无法追踪的对象的行为是不同的 - 见下文)。它也将对象复制摘要(保留修改的时间等)对象不加载在R复制时,如果复制的对象是源或目标数据库中缓存,缓存的副本将被删除。
The readonly status of both tracking dbs will be respected – the function will stop with an error before doing anything if a readonly flag conflicts with what it needs to do.
只读状态将得到尊重 - 都跟踪DBS的功能将停止与前一个错误,做任何事情,如果一个只读标志的冲突,它需要做什么。
The metadata in source and destination tracking dbs (i.e., the file map and the object summary) are updated after each object is copied. Thus, if an error occurs during copying, e.g., due to filesystem permissions or lack of space, the source and destination dbs will be left in a consistent state.
源和目的地跟踪dbs中(即,文件的图和对象摘要)被更新后的每个对象中的元数据被复制。因此,如果在复制过程中发生错误,例如,由于文件系统的权限或空间不足,在源和目标星展银行将留在一个一致的状态。
track.move calls track.copy with a default of delete=TRUE to remove the source object.
track.move调用track.copydelete=TRUE删除源对象的默认。
<STRONG>NB: do.untrackable is not yet implemented: untracked/untrackable objects are ignored.</STRONG> By default, untrackable objects in the source tracking db will not be copied or moved, and a warning will be given. The rules for untrackability are those of the destination db, as specified by the tracking options autoTrackExcludePattern and autoTrackExcludeClass in that db. If do.untrackable=TRUE, untrackable objects will be copied or moved (with delete still controlling whether the original is left or removed.) Untrackable objects that are copied are left as an ordinary untracked object in the destination db.
<STRONG>注意:do.untrackable是尚未实现:不露痕迹的/无法追踪的对象将被忽略。</ STRONG>默认情况下,在源跟踪数据库无法追踪的对象将不会被复制或移动,将发出警告。规则untrackability的目标数据库,指定的跟踪选项autoTrackExcludePattern和autoTrackExcludeClass在该数据库的。如果do.untrackable=TRUE,无法追踪的对象将被复制或移动(与delete控制是否原来是向左或删除。)无法跟踪的对象被复制留在目标DB作为一个普通的不露痕迹的对象。
值----------Value----------
A character vector of the objects copied or moved.
字符向量的对象复制或移动。
(作者)----------Author(s)----------
Tony Plate <tplate@acm.org>
实例----------Examples----------
track.start(dir="tmp1")
track.attach(dir="tmp2", pos=2, create=TRUE)
assign("x1", 1, pos=2)
assign("x2", 2, pos=2)
assign("y3", 3, pos=2)
assign("y4", 4, pos=2)
assign("z5", 5)
track.status(1)
track.status(2)
track.copy(from=2, pat="^x")
ls(1)
ls(2)
track.move(from=2, pat="^y")
track.move(from=1, to=2, pat="^z")
ls(1)
ls(2)
c(x1, x2, y3, y4)
track.move(from=2, pat="^x", clobber=TRUE)
ls(1)
ls(2)
c(x1, x2, y3, y4)
track.status(1)
track.status(2)
track.detach(2)
track.stop()
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|