Dear All,

I am trying to build an error bar plot with ggplot2. However, even if 
the code seems to work, the plot is rather odd, with what seems to be 
a continuous line linking the different bars.

I attach below the code I used, as well as the data.
================================================================
DFrame<-data.frame(x=1:10,y=0.5*(1:10),Upper=(1:10)+0.5, Lower=(1:10)-0.5)
p <- ggplot()
l1<-layer(data=DFrame, mapping=aes_string(x='x',min='Lower', 
max='Upper'), geom='errorbar', stat='identity')
p<-p + l1 + scale_y_continuous()

p

========================================
I wonder if anyone can help me with this.

Best,
Pedro de Barros

______________________________________________
R-help@r-project.org mailing list
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.

Reply via email to