disstree(TraMineR)
disstree()所属R语言包:TraMineR
Dissimilarity Tree
相异树
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Tree structured discrepancy analysis of non-measurable objects described by their pairwise dissimilarities.
树形结构差异分析的不可测量的对象所描述的两两相异的。
用法----------Usage----------
disstree(formula, data = NULL, weights = NULL, minSize = 0.05,
maxdepth = 5, R = 1000, pval = 0.01, object = NULL,
weight.permutation = "replicate", squared = FALSE,
first = NULL)
参数----------Arguments----------
参数:formula
A formula where the left hand side is a dissimilarity matrix and the right hand specifies the candidate partitioning variables
甲的左手侧是一个的相异矩阵和右手的化学式为:其中指定的候选分割变量
参数:data
A data frame where arguments in formula will be searched
式的参数将数据框搜索
参数:weights
Optional numerical vector of weights.
可选的数值向量的权重。
参数:minSize
Minimum number of cases in a node, will be treated as a proportion if less than 1.
最小数量的在一个节点中的情况下,将被处理作为一个比例如果小于1。
参数:maxdepth
Maximum depth of the tree
树的最大深度
参数:R
Number of permutations used to assess the significance of the split.
用来评估分割的意义的排列数目。
参数:pval
Maximum allowed p-value for a split
允许的最大p值分裂
参数:object
An optional R object represented by the dissimilarity matrix. This object may be used by the print method or disstree2dot to render specific object type.
一个可选的R对象的相异度矩阵表示。这个对象,可以使用print或disstree2dot呈现特定的对象类型。
参数:weight.permutation
Weight permutation method: "diss" (attach weights to the dissimilarity matrix), "replicate" (replicate cases using weights), "rounded-replicate" (replicate case using rounded weights), "random-sampling" (random assignment of covariate profiles to the objects using distributions defined by the weights.)
重量置换的方法:"diss"(附加的相异度矩阵的权重),"replicate"(复制情况下,使用weights)"rounded-replicate"(复制的情况下使用四舍五入weights,) "random-sampling"(协的对象所定义的权重分布中随机分配的。)
参数:squared
Logical: Should the diss dissimilarities be squared?
逻辑:diss不同点是平方?
参数:first
One of the variable in the right-hand side of the formula. This forces the first node of the tree to be split by this variable.
式的右手侧的中的变量之一。这迫使这个变量被分裂树的第一个节点。
Details
详细信息----------Details----------
The procedure iteratively splits the data. At each step, the procedure selects the variable and split that explain the greatest part of the discrepancy, i.e., the split for which we get the highest pseudo R2. The significance of the retained split is assessed through a permutation test.
迭代的过程分割数据。在每一个步骤,程序选择的变量和分裂解释的差异,即分裂,而我们得到最高的伪R2的最大部分。保留的分割的意义评估通过一个置换试验。
seqtree provides a simpler interface if you plan to use disstree for state sequence objects.
seqtree提供了一个简单的界面,如果你打算使用disstree状态序列对象。
值----------Value----------
An object of class disstree that contains the following components:
类的一个对象disstree“”包含以下组件:
参数:root
A node object, root of the tree
一个节点对象,树的根
参数:info
General information such as parameters used to build the tree
如参数用于构建树的一般信息
参数:info$adjustment
A dissassoc object providing global statistics for tree.
Adissassoc对象提供全局统计信息树。
参数:formula
The formula used to generate the tree
所用的公式来生成该树
参数:data
data used to build the tree
使用的数据构建树
参数:weights
weights
权重
参考文献----------References----------
Discrepancy analysis of complex objects using dissimilarities. In F. Guillet, G. Ritschard, D. A. Zighed and H. Briand (Eds.), Advances in Knowledge Discovery and Management, Studies in Computational Intelligence, Volume 292, pp. 3-19. Berlin: Springer.
Analyse de dissimilarit茅s par arbre d'induction. In EGC 2009, Revue des Nouvelles Technologies de l'Information, Vol. E-15, pp. 7-18.
Austral Ecology 26, 32-46.
Classification and related methods of data analysis, Amsterdam: North-Holland, pp. 67-74.
algorithm. Journal of the Royal Statistical Society A 170(4), 1061–1078.
参见----------See Also----------
seqtree to generate a specific disstree objects for analyzing state sequences. <br> seqtreedisplay to generate graphic representation of seqtree objects when analyzing state sequences. <br> disstreedisplay is a more general interface to generate such representation for other type of objects. <br> dissvar to compute discrepancy using dissimilarities and for a basic introduction to discrepancy analysis. <br> dissassoc to test association between objects represented by their dissimilarities and a covariate. <br> dissmfac to perform multi-factor analysis of variance from pairwise dissimilarities. <br> disscenter to compute the distance of each object to its group center from pairwise dissimilarities.
seqtree生成一个特定的disstree对象状态序列分析的。参考seqtreedisplayseqtree对象的状态序列进行分析时,生成图形表示。参考disstreedisplay是一个更通用的接口,产生这样的表现对于其他类型的对象。参考dissvar计算差异使用不同点和差异分析的基本介绍。参考dissassoc,以测试他们的不同点和协变量所代表的对象之间的关联。参考dissmfac进行多因素方差分析,两两相异。参考disscenter计算两两相异的每个对象组中心的距离。
实例----------Examples----------
data(mvad)
## Defining a state sequence object[#定义一个状态序列对象]
mvad.seq <- seqdef(mvad[, 17:86])
## Computing dissimilarities (any dissimilarity measure can be used)[#计算相异(可用于任何相异措施)]
mvad.ham <- seqdist(mvad.seq, method="HAM")
dt <- disstree(mvad.ham~ male + Grammar + funemp + gcse5eq + fmpr + livboth,
data=mvad, R = 10)
print(dt)
## Will only work if GraphViz is properly installed[#只会工作,如果GraphViz的正确安装]
## See seqtree for simpler way to plot a sequence tree.[#请参阅seqtree简单的方法来绘制一个序列树。]
## Not run: [#不运行:]
disstreedisplay(dt, imagefunc=seqdplot, imagedata=mvad.seq,
## Additional parameters passed to seqdplot[#参数传递到seqdplot的]
withlegend=FALSE, axes=FALSE, ylab="")
## End(Not run)[#(不执行)]
## Second method, using a specific function[#第二方法,使用一个特定的函数]
myplotfunction <- function(individuals, seqs, ...) {
par(font.sub=2, mar=c(3,0,6,0), mgp=c(0,0,0))
## using mds to order sequence in seqiplot[#使用MDS层序seqiplot]
mds <- cmdscale(seqdist(seqs[individuals,], method="HAM"),k=1)
seqiplot(seqs[individuals,], sortv=mds,...)
}
## If imagedata is not set, index of individuals are sent to imagefunc[#如果设置不ImageData中,索引被发送到个人imagefunc]
## Not run: [#不运行:]
disstreedisplay(dt, imagefunc=myplotfunction, title.cex=3,
## additional parameters passed to myplotfunction[#额外的参数传递给myplotfunction]
seqs=mvad.seq,
## additional parameters passed to seqiplot (through myplotfunction)[#额外的参数传递到seqiplot的(通过myplotfunction)]
withlegend=FALSE, axes=FALSE, tlim=0, space=0, ylab="", border=NA)
## End(Not run)[#(不执行)]
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|