Quantcast
Channel: Recent Questions - Stack Overflow
Viewing all articles
Browse latest Browse all 11631

Adding standard error bars to a bar graph

$
0
0

Hi i am trying to work how to add standard error bars to my bar plot on r but i can't quite work it out!

This is my bar plot code:ggplot(data=pdiv, aes(x= Area, y = Diversity, fill=Area)) + geom_col() + theme_bw() + xlab("Area") + ylab("Simpson's Diversity Index score") + scale_fill_manual(breaks = c("A", "B", "C", "D"), values = c("indianred1", "mediumorchid3", "lightgreen", "lightblue"))

I've tried calculating means and then doing it manually but that doesn't seem to work.


Viewing all articles
Browse latest Browse all 11631

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>