verboseBarplot(WGCNA)
verboseBarplot()所属R语言包:WGCNA
Barplot with error bars, annotated by Kruskal-Wallis or ANOVA p-value
Barplot与的错误条形,注明秩和检验或方差分析的p值
译者:生物统计家园网 机器人LoveR
描述----------Description----------
Produce a barplot with error bars, annotated by Kruskal-Wallis or ANOVA p-value.
产生barplot的错误条形,注明秩和检验或方差分析的p值。
用法----------Usage----------
verboseBarplot(x, g,
main = "", xlab = NA, ylab = NA,
cex = 1, cex.axis = 1.5, cex.lab = 1.5, cex.main = 1.5,
color = "grey", numberStandardErrors = 1,
KruskalTest = TRUE, AnovaTest = FALSE, two.sided = TRUE,
horiz = FALSE, ...)
参数----------Arguments----------
参数:x
numerical vector of data whose group means are to be plotted
数值向量组意味着要绘制的数据
参数:g
a factor or a an object coercible to a factor giving the groups whose means are to be calculated.
因子或一个对象转换成给出的基团,其装置是要计算的一个因素。
参数:main
main title for the plot.
主标题的图。
参数:xlab
label for the x-axis.
标签的x轴。
参数:ylab
label for the y-axis.
标签的y轴。
参数:cex
character expansion factor for plot annotations.
图注释字符的膨胀系数。
参数:cex.axis
character expansion factor for axis annotations.
轴注释字符的膨胀系数。
参数:cex.lab
character expansion factor for axis labels.
字符膨胀系数轴标签。
参数:cex.main
character expansion factor for the main title.
字符膨胀系数的主标题。
参数:color
a vector giving the colors of the bars in the barplot.
一个向量给的条形在barplot的颜色。
参数:numberStandardErrors
size of the error bars in terms of standard errors. See details.
尺寸误差线的标准误差。查看详细信息。
参数:KruskalTest
logical: should Kruskal-Wallis test be performed? See details.
逻辑:Kruskal-Wallis检验进行?查看详细信息。
参数:AnovaTest
logical: should ANOVA be performed? See details.
逻辑:应ANOVA进行?查看详细信息。
参数:two.sided
logical: should the printed p-value be two-sided? See details.
逻辑:应双面印刷p值吗?查看详细信息。
参数:horiz
logical: should the bars be drawn horizontally?
逻辑:应绘制水平的条形吗?
参数:...
other parameters to function barplot
其他参数的功能barplot
Details
详细信息----------Details----------
This function creates a barplot of a numeric variable (input x) across the levels of a grouping variable (input g). The height of the bars equals the mean value of x across the observations with a given level of g. By default, the barplot also shows plus/minus one standard error. If you want only plus one standard error (not minus) choose two.sided=TRUE. But the number of standard errors can be determined with the input numberStandardErrors. For example, if you want a 95% confidence interval around the mean, choose numberStandardErrors=2. If you don't want any standard errors set numberStandardErrors=-1. The function also outputs the p-value of a Kruskal Wallis test, which is a non-parametric multi group comparison test. Alternatively, one can use Analysis of Variance (Anova) to compute a p-value by setting AnovaTest=TRUE. Anova is a generalization of the Student t-test to multiple groups. In case of two groups, the Anova p-value equals the Student t-test p-value. Anova should only be used if x follows a normal distribution. Anova also assumes homoscedasticity (equal variances). The Kruskal Wallis test is often advantageous since it makes no distributional assumptions. Since the Kruskal Wallis test is based on the ranks of x, it is more robust with regard to outliers. All p-values are two-sided.
这个函数创建一个barplot的数值变量(输入x)水平之间的一组变量(输入g)。矩形条的高度等于x整个观测g与一个给定的电平的平均值。默认情况下,barplot也显示加/减一个标准的错误。如果你想只加1个标准误差(减)选择two.sided=TRUE。但是,标准误差的数目可以取决于与输入numberStandardErrors。例如,如果你想有一个平均的95%置信区间,选择numberStandardErrors=2。如果你不希望任何标准的错误numberStandardErrors=-1。该函数也输出一个克鲁斯卡尔Wallis检验,这是一个非参数的多组间比较试验的p-值。另外,我们可以使用方差分析(ANOVA)来计算通过设置AnovaTest=TRUEp值。方差分析是一个概括的学生t-检验到多个组。两组的情况下,方差分析的p值等于学生的t检验p值。如果x服从正态分布,方差分析应该只用于。方差分析还假定方差齐性(方差相等)。往往是有利的,因为它使没有分布假设的Kruskal Wallis检验。由于克鲁斯卡尔沃利斯测试的根据的行列x,它是关于离群的鲁棒性。所有的p值是双面的。
值----------Value----------
None.
无。
(作者)----------Author(s)----------
Steve Horvath
参见----------See Also----------
barplot
barplot
实例----------Examples----------
group=sample(c(1,2),100,replace=TRUE)
height=rnorm(100,mean=group)
par(mfrow=c(2,2))
verboseBarplot(height,group, main="1 SE, Kruskal Test")
verboseBarplot(height,group,numberStandardErrors=2,
main="2 SE, Kruskal Test")
verboseBarplot(height,group,numberStandardErrors=2,AnovaTest=TRUE,
main="2 SE, Anova")
verboseBarplot(height,group,numberStandardErrors=2,AnovaTest=TRUE,
main="2 SE, Anova, only plus SE", two.sided=FALSE)
转载请注明:出自 生物统计家园网(http://www.biostatistic.net)。
注:
注1:为了方便大家学习,本文档为生物统计家园网机器人LoveR翻译而成,仅供个人R语言学习参考使用,生物统计家园保留版权。
注2:由于是机器人自动翻译,难免有不准确之处,使用时仔细对照中、英文内容进行反复理解,可以帮助R语言的学习。
注3:如遇到不准确之处,请在本贴的后面进行回帖,我们会逐渐进行修订。
|