triplet(spam)
triplet()所属R语言包:spam
Transform a spam format to triplets
垃圾邮件的格式转换三胞胎
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Returns a list containing the indices and elements of a spam object.
返回一个列表,其中包含的指标和要素的spam对象。
用法----------Usage----------
triplet(x, tri=FALSE)
参数----------Arguments----------
参数:x
sparse matrix of class spam or a matrix.
稀疏矩阵类spam或矩阵。
参数:tri
Boolean indicating whether to create individual row and column indices vectors.
布尔值,指示是否要创建单独的行和列向量。
Details
详细信息----------Details----------
The elements are row (column) first if x is a spam object (matrix).<br>
这些元素是行(列)第一,如果x是spam对象(矩阵)。<BR>的
值----------Value----------
A list with elements
元素列表
参数:indices
a by two matrix containing the indices if tri=FALSE.
一个由两个矩阵的指数,如果tri=FALSE。
参数:i,j
vectors containing the row and column indices if tri=TRUE.
向量的行和列,如果tri=TRUE。
参数:values
a vector containing the matrix elements.
矩阵元素的向量,包含。
(作者)----------Author(s)----------
Reinhard Furrer
参见----------See Also----------
spam.list for the inverse operation and
spam.list的逆操作
实例----------Examples----------
x <- diag.spam(1:4)
x[2,3] <- 5
triplet(x)
all.equal( spam( triplet(x, tri=TRUE)), x)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|