[R] barplots with standard deviation
mcw at ln.nimh.nih.gov
Mon Oct 2 16:01:55 CEST 2000
barplot returns a matrix of the x-centers. You can use this to add to the
Say mp is what is returned by barplot, you could do something like
arrows(mp, heights, mp, heights + std.dev, angle = 90)
or use segments if you don't want the crossbar.
There's an example of this (and other things you could add to the
barplot) in the help file for barplot.
Hope this helps.
On Mon, 2 Oct 2000, Raoul Boenisch wrote:
> I'd like to print certain kinds of diagrams with R. They should
> look like barplots with besides=TRUE, but also have the variance
> or standard deviation on every bar so that one could better
> compare the bars. How could I apply this?
> thanks for your help
> r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
> Send "info", "help", or "[un]subscribe"
> (in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
More information about the R-help