blockmodel(sna)
blockmodel()所属R语言包:sna
Generate Blockmodels Based on Partitions of Network Positions
基于网络位置的分区生成Blockmodels
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Given a set of equivalence classes (in the form of an equiv.clust object, hclust object, or membership vector) and one or more graphs, blockmodel will form a blockmodel of the input graph(s) based on the classes in question, using the specified block content type.
给定一组等价类(在一个equiv.clust对象的形式,hclust对象,或成员资格向量)和一个或多个图形,blockmodel将形成一个块模型的输入图( S)的基础上,使用指定的块内容类型中的类问题。
用法----------Usage----------
blockmodel(dat, ec, k=NULL, h=NULL, block.content="density",
plabels=NULL, glabels=NULL, rlabels=NULL, mode="digraph",
diag=FALSE)
参数----------Arguments----------
参数:dat
one or more input graphs.
一个或多个输入图表。
参数:ec
equivalence classes, in the form of an object of class equiv.clust or hclust, or a membership vector.
等价类,在对象类equiv.clust或hclust,或成员资格向量的形式。
参数:k
the number of classes to form (using cutree).
的班数形式(使用cutree“)。
参数:h
the height at which to split classes (using cutree).
高度分裂类(使用cutree“)。
参数:block.content
string indicating block content type (see below).
字符串,指示块的内容类型(见下文)。
参数:plabels
a vector of labels to be applied to the individual nodes.
要施加到单个节点中的标签的向量。
参数:glabels
a vector of labels to be applied to the graphs being modeled.
要施加到标签的向量的所建模的曲线图。
参数:rlabels
a vector of labels to be applied to the (reduced) roles.
要施加到标签的向量的(减少)角色。
参数:mode
a string indicating whether we are dealing with graphs or digraphs.
一个字符串,指示是否我们正在处理的图或有向图。
参数:diag
a boolean indicating whether loops are permitted.
一个布尔值,指示是否被允许循环。
Details
详细信息----------Details----------
Unless a vector of classes is specified, blockmodel forms its eponymous models by using cutree to cut an equivalence clustering in the fashion specified by k and h. After forming clusters (roles), the input graphs are reordered and blockmodel reduction is applied. Currently supported reductions are:
除非指定的向量类,blockmodel形成了自己的名字命名的车型通过使用cutree削减等价聚类在指定的k和h的时尚。成形后的簇(角色)中,输入图形重新排序和块模型减少被施加。目前支持的减少是:
<ol> density: block density, computed as the mean value of the block
<OL>density:块密度,作为该块的平均值计算
meanrowsum: mean row sums for the block
meanrowsum的意思行款项块
meancolsum: mean column sums for the block
meancolsum:指列和块
sum: total block sum
sum:总块总和
median: median block value
median:格挡值中位数
min: minimum block value
min:最小的块值
max: maximum block value
max:最大块值
types: semi-intelligent coding of blocks by “type.” Currently recognized types are (in order of precedence) “NA” (i.e., blocks with no valid data), “null” (i.e., all values equal to zero), “complete” (i.e., all values equal to 1), “1 covered” (i.e., all rows/cols contain a 1), “1 row-covered” (i.e., all rows contain a 1), “1 col-covered” (i.e., all cols contain a 1), and “other” (i.e., none of the above). </ol>
types:半智能编码块的“类型”。目前公认的类型(按优先顺序)“NA”(即,没有有效的数据块),“ “空”(即,所有的值等于0),“完成”(即,所有的值等于1),“覆盖”(即,所有的行/列包含1),“1行覆盖” (即,所有的行包含1),“1山坳覆盖”(即所有列包含1),和“其他”(即没有以上)。 </ OL>
Density or median-based reductions are probably the most interpretable for most conventional analyses, though type-based reduction can be useful in examining certain equivalence class hypotheses (e.g., 1 covered and null blocks can be used to infer regular equivalence classes). Once a given reduction is performed, the model can be analyzed and/or expansion can be used to generate new graphs based on the inferred role structure.
密度或中位数的减少可能是最常规的分析解释,虽然在研究的若干等价类的假设(例如,覆盖和空块可以用来推断定期等价类)型为主的减少可能是有用的。一旦一个给定的减少被执行时,该模型可以被分析和/或扩展可用于生成新的图形的基础上推断角色结构。
值----------Value----------
An object of class blockmodel.
对象的类blockmodel。
(作者)----------Author(s)----------
Carter T. Butts <a href="mailto:buttsc@uci.edu">buttsc@uci.edu</a>
参考文献----------References----------
Doreian, P.; Batagelj, V.; and Ferligoj, A. (2005). Generalized Blockmodeling. Cambridge: Cambridge University Press.
参见----------See Also----------
equiv.clust, blockmodel.expand
equiv.clust,blockmodel.expand
实例----------Examples----------
#Create a random graph with _some_ edge structure[创建一个随机的图形_some_边缘结构]
g.p<-sapply(runif(20,0,1),rep,20) #Create a matrix of edge [创建一个矩阵的边缘]
#probabilities[概率]
g<-rgraph(20,tprob=g.p) #Draw from a Bernoulli graph [从伯努利图绘制]
#distribution[分配]
#Cluster based on structural equivalence[聚类基于结构等价]
eq<-equiv.clust(g)
#Form a blockmodel with distance relaxation of 10[形成一个块模型的距离松弛10]
b<-blockmodel(g,eq,h=10)
plot(b) #Plot it[画出它]
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|