Plot mean, standard deviation, standard error of the mean, and confidence interval
names=data$method
x = 1:13*2-1
CI.up = as.numeric(data$mean)+as.numeric(data$ci)
CI.dn = as.numeric(data$mean)-as.numeric(data$ci)
plot(data$mean~x, cex=1.5,xaxt='n',ylim=c(0.3,0.40), xlab='',ylab='lalala!', main='blahblahblah',col='blue',pch=16)
axis(1, at=x, labels=names)
arrows(x,CI.dn,x,CI.up,code=3,length=0.2,angle=90,col='red')
legend("bottomleft",paste(names,": S.E=",data$se),ncol=6,text.width=1)
output
Boxplot overlaid on dot plot + means, means in wrong position
The help for ?position_dodge just says that dodging things with different widths is tricky - I usually tweak this manually. Trying a few values, it looks like you want the points to take a dodge width that is 3/4 of the boxplot width but I don't know why or if that holds for other geoms. I would try changing the width for the stat_summary call to 0.15
Related Topics
Rank a Vector Based on Order and Replace Ties with Their Average
Change Level of Multiple Factor Variables
Running Multiple Linear Regressions Across Several Columns of a Data Frame in R
Difference Between Mean(C(1,2,21)) and Mean(1,2,21)
Ggplot Aes_String Does Not Work Inside a Function
Unique Elements of Two Vectors
Evaluate (I.E., Predict) a Smoothing Spline Outside R
How to Make a Post Request with Header and Data Options in R Using Httr::Post
Gathering Wide Columns into Multiple Long Columns Using Pivot_Longer
Compute All Fixed Window Averages with Dplyr and Rcpproll
Replacing the Duplicate Values Except 1 Row in R Dataframe
How to Get Rows, by Group, of Data Frame with Earliest Timestamp
Is R Superstitious Regarding Posixct Data Type
How to Remove Rows with All Zeros Without Using Rowsums in R
Aggregate by Specific Year in R