Skip to content
Prev 333761 / 398506 Next

Conditional error bars

Change your two lines
to the one line
       arrows(xvals, mean, xvals, mean + sign(mean) * se, angle=90, length=length)

(I would also use a scatter plot instead of a barplot for this sort of thing and
draw both error bars.  I think the bars give a misleading impression of what
is going on.)

Bill Dunlap
Spotfire, TIBCO Software
wdunlap tibco.com