Note that linejoin
is a parameter to certain (but not all) geoms that draw lines, but it is not an aesthetic (that is, it can not be used in a mapping via a scale but can only be set to a constant value for any given layer).
The linejoin
parameter accepts one of three possible legal values: "round", "mitre", or "bevel". The default is "round".
d=data.frame(x=c(0,2,0), y=c(0,1,2)) t=data.frame(x=c(0,1,2), l=c("round", "mitre", "bevel")) ggplot() + geom_path(data=d, mapping=aes(x=x, y=y), size=10, linejoin="round") + geom_path(data=d, mapping=aes(x=x+1, y=y), size=10, linejoin="mitre", linemitre=10) + geom_path(data=d, mapping=aes(x=x+2, y=y), size=10, linejoin="bevel") + geom_path(data=d, mapping=aes(x=x, y=y), size=1, color="white") + geom_path(data=d, mapping=aes(x=x+1, y=y), size=1, color="white") + geom_path(data=d, mapping=aes(x=x+2, y=y), size=1, color="white") + geom_text(data=t, mapping=aes(x=x+1.75, y=1, label=l), hjust=1, vjust=0.5)