找回密码
 注册
查看: 418|回复: 0

R语言 externalVector包 as.Rvector()函数中文帮助文档(中英文对照)

[复制链接]
发表于 2012-2-25 17:24:39 | 显示全部楼层 |阅读模式
as.Rvector(externalVector)
as.Rvector()所属R语言包:externalVector

                                         convert an object to an R basic vector or matrix
                                         转换为对象的R基本向量或矩阵

                                         译者:生物统计家园网 机器人LoveR

描述----------Description----------

as.Rvector, a generic, attempts to coerce its argument into a basic R vector of a convenient mode. All attributes of x are preserved.
as.Rvector,一个通用的,试图强迫它的参数,进入了一个方便的模式基本科研向量。属性所有x的被保留。

Default methods are provided for basic R objects which are returned unchanged by as.Rvector.
默认的方法是提供基本科研对象返回由as.Rvector不变。

as.Rmatrix, a generic, first converts its argument to a basic R vector and then applies as.matrix to the result.
as.Rmatrix,一个通用的,首先它的参数转换到基本科研向量,然后as.matrix结果。


用法----------Usage----------


as.Rvector(x)
as.Rmatrix(x)



参数----------Arguments----------

参数:x
An object  
对象


Details

详情----------Details----------

This preserves all the non-slot attributes of the object x when converting to a basic R vector. In addition, if any of dim(x), dimnames(x), names(x) is not NULL, the corresponding attribute in the result is also set.
这将保留对象的所有非槽的属性x当转换到一个基本科研向量。此外,如果任何dim(x),dimnames(x),names(x)是不是NULL结果中的相应属性也被设置。


值----------Value----------

The value from as.Rvector is a basic R vector of mode "logical", "integer", "numeric", "complex", "character" or "list". The value from as.Rmatrix is a basic R matrix.
从as.Rvector值是基本科研向量的“逻辑”模式,“整数”,“数字”,“复杂”,“性格”或“列表”。从as.Rmatrix值是一个基本的R矩阵。


参见----------See Also----------

as.vector for converting an object to an appropriate vector with all attributes removed and as.matrix for converting a vector like object to a
as.vector转换为对象的所有属性中删除和as.matrix转换为一个向量类对象到一个合适的向量


举例----------Examples----------


x <- 1:2
names(x) <- letters[1:2]
as.vector(x)
as.Rvector(x)
as.Rmatrix(x)

转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。


注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

手机版|小黑屋|生物统计家园 网站价格

GMT+8, 2025-2-9 14:01 , Processed in 0.022210 second(s), 15 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表