エラーバーを加える
(dfc
であらかじめse
の値を持っておいた上で)
ggplot(dfc, aes(x=dose, y=len, colour=supp)) +
geom_errorbar(aes(ymin=len-se, ymax=len+se), width=.1) +
geom_line() +
geom_point()
エラーバーのtick(?)の幅は width
で設定できる。
http://www.cookbook-r.com/Graphs/Plotting_means_and_error_bars_(ggplot2)/