This is a test version of Biostars. For the public version, visit https://www.biostars.org.
lots of Error-bars appear with geom_errorbar

I used ggplot2 for drawing my bar plots and after adding geom_errorbars I get many error bars stacked on each other (picture below).

What's the problem? I tried to draw it both in Windows and Linux to make sure the problem is not from my R version, and I got the same results.

ggplotf.tm,aes(Gene,Expression,fill=Group)) +
  geom_bar(stat="identity", position=position_dodge())+
  geom_errorbar(aes(ymin=Expression-sd, ymax=Expression+sd), width=.2,
                position=position_dodge(.9))

enter image description here

r ggplot2

Hello Sadegh Ghasemi!

We believe that this post does not fit the main topic of this site.

Pure ggplot please ask at StackOverflow and be sure to provide example data via dput for reproduction.

For this reason we have closed your question. This allows us to keep the site focused on the topics that the community can help with.

If you disagree please tell us why in a reply below, we'll be happy to talk about it.

Cheers!

0 answers

No answers yet.

Log in to answer this question.