Bugs in geom_path and geom_line when group is used

43 views
Skip to first unread message

Karl Ove Hufthammer

unread,
Sep 24, 2009, 9:33:33 AM9/24/09
to ggp...@googlegroups.com
Similar to the alpha problem in my last post, I think there also is a
bug in 'group' with geom_path and geom_line. Example:

n=10
x=rnorm(n)
y=rnorm(n)
z=seq(n)
w=sample(rep(c("A","B"),each=n/2))

# Shouldn't the colours used for the two 'lines' be identical here?
qplot(x,y,colour=z,geom="line",group=w,size=I(2))

# Shouldn't the colours used for the two 'lines' be identical here?
qplot(x,y,colour=z,geom="path",group=w,size=I(2))

# And using alpha now causes a problem with geom_line too,
# not just with geom_path, as in my previous bug report
qplot(x,y,alpha=z,geom="line",group=w,size=I(2))
qplot(x,y,alpha=z,geom="path",group=w,size=I(2))

--
Karl Ove Hufthammer

Karl Ove Hufthammer

unread,
Sep 24, 2009, 12:38:26 PM9/24/09
to Karl Ove Hufthammer, ggp...@googlegroups.com
Quoting Karl Ove Hufthammer <Karl.Hu...@math.uib.no>:

> # Shouldn't the colours used for the two 'lines' be identical here?
> qplot(x,y,colour=z,geom="line",group=w,size=I(2))

No, of course they shouldn't. Ignore this comment. The following
problem is real, though.

> # And using alpha now causes a problem with geom_line too,
> # not just with geom_path, as in my previous bug report
> qplot(x,y,alpha=z,geom="line",group=w,size=I(2))
> qplot(x,y,alpha=z,geom="path",group=w,size=I(2))

--
Mvh.
Karl Ove Hufthammer

Reply all
Reply to author
Forward
0 new messages