2

I have a list of Gadfly layers with an unknown size:

lines = [layer(x=x,y=i*x) for i in range(1,stop=3)]

Now I would like to draw all of them in one plot. But Gadfly expects a number of single layers, rather than a list of layers. So plot(lines) doesn't work but plot(lines[1], lines[2], lines[3]) does.

In Python I'd just use the splat operator plot(*lines).

How can do something like this in Julia?

Stein
  • 3,179
  • 5
  • 27
  • 51

1 Answers1

1

Try to splat it with ...

plot(lines...)
xiaodai
  • 14,889
  • 18
  • 76
  • 140