Hello, I'm getting a warning message from the reproducible example below.
Why would geom_errorbar() remove 2 cases in this case? Both upper and lower limits of the error bar contain var1 and are within the axis limits. df <- data.frame(var1 = seq(0, 1, 0.1), var2 = seq(0, 1, 0.1)) df$ll <- ifelse(df$var1 == 0, 0, df$var1 - 0.05) df$ul <- ifelse(df$var1 == 1, 1, df$var1 + 0.05) pp1 <- ggplot(data = df, aes(x = var2, y = var1)) + geom_line() + geom_point() + scale_x_continuous(limits = c(0, 1), breaks = seq(0, 1, 0.1)) + scale_y_continuous(limits = c(0, 1), breaks = seq(0, 1, 0.1)) pp1 pp2 <- pp1 + geom_errorbar(data=df, aes(ymin=ll,ymax=ul), width=0.02) pp2 Warning message: In loop_apply(n, do.ply) : Removed 2 rows containing missing values (geom_path). > Thanks for any pointers. Best, Axel. [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.