How to make this plot in Julia?

Thanks @juliohm I was under the impression that Gadfly was stalled, but that appears to be a misunderstanding.

It actually does ok:

Gadfly

billede

With proper name-spacing and extra packages it also works from Weave:

using Gadfly, Cairo, Fontconfig
plot(d, x=:time, y=:value, color=:name, label=:name, 
  Gadfly.Geom.point(), Gadfly.Geom.line(), Gadfly.Geom.label())

Thanks for making me re-visit that.

AlgebraOfGraphics

I’m not able to find a way to add text-labels on the plot in AlgebraOfGraphics.

This is as close as I can get:

using AlgebraOfGraphics, GLMakie
plt = data(d) * (visual(Scatter) + visual(Lines) ) * 
      mapping(:time, :value, color = :name);
AlgebraOfGraphics.draw(plt)

Also, I’m not able to get the AOG plot to work from Weave.

VegaLite

In VegaLite, I can plot points or lines or text-labels, but I can not figure out how to combine them:

using VegaLite
d |> @vlplot(:line, x = :time, y= :value, color = :name)

billede

1 Like