bar.err {agricolae}R Documentation

Plotting the standard error or standard deviance of a multiple comparison of means

Description

It plots bars of the averages of treatments and standard error or standard deviance. It uses the objects generated by a procedure of comparison like LSD, HSD, Kruskal and Waller-Duncan.

Usage

bar.err(x,variation=c("SE","SD","range"),horiz=FALSE, bar=TRUE,...)

Arguments

x

object means of the comparisons the LSD.test, HSD.test,...,etc

variation

SE=standard error or range=Max-Min

horiz

Horizontal or vertical bars

bar

paint bar

...

Parameters of the function barplot()

Details

x: data frame formed by 5 columns: name of the bars, height, level out: LSD.test, HSD, waller.test, scheffe.test, duncan.test, SNK.test, friedman, kruskal, waerden.test. x: out$means

Value

x

object

variation

character std, SE or range

horiz

TRUE or FALSE

bar

TRUE or FALSE

...

Parameters of the function barplot()

Author(s)

Felipe de Mendiburu

See Also

LSD.test, HSD.test, waller.test, kruskal, bar.group

Examples

library(agricolae)
data(sweetpotato)
model<-aov(yield~virus,data=sweetpotato)
out <- waller.test(model,"virus", console=TRUE,
main="Yield of sweetpotato\ndealt with different virus")
par(mfrow=c(2,2),cex=1)
bar.err(out$means,variation="range",horiz=TRUE,xlim=c(0,45),angle=125,density=6,
 main="range")
bar.err(out$means,variation="SD",ylim=c(0,45),col=colors()[30],
 main="Standard deviation",density=8)
bar.err(out$means,variation="SE",horiz=TRUE,xlim=c(0,45),density=8,
 col="brown",main="Standard error")
bar.err(out$means,variation="range",ylim=c(0,45),bar=FALSE,col="green",
 main="range")
par(mfrow=c(1,2),cex=1)
bar.err(out$means,variation="range",ylim=c(0,45),bar=FALSE,col=0)
abline(h=0)
# horiz = TRUE
bar.err(out$means,variation="SE",horiz=TRUE,xlim=c(0,45),bar=FALSE,col=0)
#startgraph
par(mfrow=c(1,1))
#endgraph

[Package agricolae version 1.2-6 Index]