library(Hmisc) means <- c(2.96, 3.59) bp = barplot(means, ylim=c(0,6), names.arg = c("Black", "White"), ylab="Support for life in prison without parole", xlab="Race of the convicted teen", xpd=T, width=c(0.2,0.2), xlim=c(0,1), space=c(1,1), main="Black Non-Hispanic Respondents") se <- c(0.2346, 0.2022) lower = c(2.48, 3.19) upper = c(3.42, 4.00) errbar(bp, means, upper, lower, add=T) box(bty="O")