AlgebraOfGraphics plots with error bars and different line styles

I’m enjoying AlgebraOfGraphics a lot, thank you so much for this package. I have a problem though: I want to use visual(Errorbars) + visual(Lines) in a figure that also specifies LineStyle. I understand that LineStyle should be part of the aesthetic mapping of Errorbars for this to work, but what would be the way to circumvent this?

If not yet documented, maybe this could be added somewhere, because line plots with different line styles and error bars are a rather common case, unless I’m biased by my bubble :slight_smile:

Thanks!

Do you mean something other than

mapping([1, 2, 3], [4, 5, 3]) * visual(Lines) + mapping([1, 2, 3], [4, 5, 3], [0.5, 0.6, 0.7]) * visual(Errorbars, linestyle = :dash) |> draw

Thanks, that was perfect! I forgot this can be done in two ways, the one you mentioned being more flexible.