attrDataItem-methods(graph)
attrDataItem-methods()所属R语言包:graph
Get and set attributes values for items in an attrData object
获取和设置属性值的项目在attrData对象
译者:生物统计家园网 机器人LoveR
描述----------Description----------
The attrDataItem method provides get/set access to items stored in a attrData-class object.
attrDataItem方法提供的get / set访问attrData-class对象中存储的项目。
用法----------Usage----------
attrDataItem(self, x, attr)
attrDataItem(self, x, attr) <- value
参数----------Arguments----------
参数:self
A attrData-class instance
一个attrData-class实例
参数:x
A character vector of item names
一个character向量项目名称
参数:attr
A character vector of length 1 giving the attribute name to get/set. Note that the attribute name must have already been defined for the attrData object via attrDefaults. If missing, return a list of all attributes for the specified nodes.
一个character向量长度1给属性的名称,以获取/设置。注意attrData对象,属性名必须已经被定义通过attrDefaults。如果丢失,返回指定节点的所有属性的列表。
参数:value
An R object to set as the attribute value for the specified items. If the object has length one or does not have a length method defined, it will be assigned to all items in x. If the length of value is the same as x, the corresponding elements will be assigned. We will add an argument to indicate that the value is to be taken as-is for those cases where the lengths are the same coincidentally.
一个R对象设置属性值指定的项目。如果对象有一个长度或没有定义长度的方法,将被分配到的所有项目在x。如果的value长度是x,相应的元素将被分配相同。我们将添加一个参数,表明value是要采取的长度是相同的巧合的情况下,作为。
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|