struc_assoc(vcd)
struc_assoc()所属R语言包:vcd
Core-generating Function for Association Plots
核心产生的关联绘图功能
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Core-generating function for strucplot returning a function producing association plots.
strucplot返回了一个函数生产协会图的核心的功能。
用法----------Usage----------
struc_assoc(compress = TRUE, xlim = NULL, ylim = NULL,
yspace = unit(0.5, "lines"), xscale = 0.9, gp_axis = gpar(lty = 3))
参数----------Arguments----------
参数:compress
logical; if FALSE, the space between the rows (columns) are chosen such that the total heights (widths) of the rows (column) are all equal. If TRUE, the space between the rows and columns is fixed and hence the plot is more “compressed”.
逻辑;如果FALSE,之间的空间中的行(列)被选择,使得总的高度(宽度)的行(列)都是相等的。如果TRUE,的行和列之间的空间是固定的,因此,图是“压缩”。
参数:xlim
either a 2 x k matrix of doubles, k the number of total columns of the plot, or a recycled vector from which such a matrix will be constructed. The columns of xlim correspond to the columns of the association plot, the rows describe the column ranges (minimums in the first row, maximums in the second row). If xlim is NULL, the ranges are determined from the residuals according to compress (if TRUE: widest range from each column, if FALSE: from the whole association plot matrix).
无论是一个2 x k的矩阵一倍,k的图,或回收向量,将建造这样一个矩阵的列数的数量。 xlim相对应的关联图的列的列中,行描述的列范围(最小值在第一行中,在第二行中的最大值)。如果xlim是NULL(compress,范围确定的残差根据如果TRUE:范围最广的每一列,如果FALSE:从整个协会图的矩阵)。
参数:ylim
either a 2 x k matrix of doubles, k the number of total rows of the plot, or a recycled vector from which such a matrix will be constructed. The columns of ylim correspond to the rows of the association plot, the rows describe the column ranges (minimums in the first row, maximums in the second row). If ylim is NULL, the ranges are determined from the residuals according to compress (if TRUE: widest range from each row, if FALSE: from the whole association plot matrix).
无论是一个2 x k的矩阵一倍,k总的图,或回收的向量,将建造这样一个矩阵的行数。 ylim对应关联图的行,行的列描述的列范围(最小值在第一行中,在第二行中的最大值)。如果ylim是NULL,范围确定的残差根据compress(如果TRUE:范围最广的每一行,如果FALSE:从整个协会图的矩阵)。
参数:xscale
scale factor resizing the tile's width, thus adding additional space between the tiles.
瓷砖之间的比例因子调整瓷砖的宽度,从而增加了额外的空间。
参数:yspace
object of class "unit" specifying additional space separating the rows.
对象的类"unit"指定额外的空格分隔的行。
参数:gp_axis
object of class "gpar" specifying the visual aspects of the tiles' baseline.
类的对象"gpar"指定的视觉方面的瓷砖的基线。
Details
详细信息----------Details----------
This function is usually called by strucplot (typically when called by assoc) and returns a function used by strucplot to produce association plots.
此功能通常被称为strucplot(通常称为assoc),并返回一个函数使用strucplot产生关联图。
值----------Value----------
A function with arguments:
的功能与参数:
参数:residuals
table of residuals.
表的残留物。
参数:observed
not used by struc_assoc.
不使用struc_assoc。
参数:expected
table of expected frequencies.
预期的频率表。
参数:spacing
object of class "unit" specifying the space between the tiles.
类的对象"unit"指定的瓷砖之间的空间。
参数:gp
list of gpar objects used for the drawing the tiles.
列表gpar对象用于绘制的瓷砖。
参数:split_vertical
vector of logicals indicating, for each dimension of the table, the split direction.
向量的逻辑值表示,该表为每个维度,分割方向。
(作者)----------Author(s)----------
David Meyer <a href="mailtoavid.Meyer@R-project.org">David.Meyer@R-project.org</a>
参考文献----------References----------
On the graphical display of the significant components in a two-way contingency table. Communications in Statistics—Theory and Methods, A9, 1025–1041.
Graphical methods for categorical data. SAS User Group International Conference Proceedings, 17, 190–200. http://datavis.ca/sugi/sugi17.pdf
The strucplot framework: Visualizing multi-way contingency tables with <code>vcd</code>. Journal of Statistical Software, 17(3), 1-48. URL http://www.jstatsoft.org/v17/i03/ and available as <code>vignette("strucplot")</code>.
参见----------See Also----------
assoc, strucplot, structable
assoc,strucplot,structable
实例----------Examples----------
## UCB Admissions[#UCB招生]
data("UCBAdmissions")
ucb <- aperm(UCBAdmissions)
## association plot for conditional independence[#协会图的有条件独立]
strucplot(ucb, expected = ~ Dept * (Admit + Gender),
core = struc_assoc(ylim = c(-4, 4)), labeling_args = list(abbreviate = c(Admit = 3)))
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|