The behavior is currently undefined if you pass in the same plot twice.
Unless there's a compelling reason, I don't think that will change.

On Monday, November 14, 2016, Scott T <sgseaborg...@gmail.com> wrote:

> Oh my mistake, I see you have supplied plot_5 twice. If I do that, I get
> the problem you describe.
>
> I'm not quite sure why you'd want to repeat a plot, but it looks like this
> is causing problems. If you really want to include plot_5 twice, I suggest
> making a new plot_6 with the same parameters and including that instead.
>
> I'll open a bug report at Plots for this behaviour.
>
> Scott
>
> On Monday, 14 November 2016 11:59:45 UTC, Scott T wrote:
>>
>> The layout has space for 6 plots but the final plot command only supplies
>> 5. When I run your example (on the development branch of Plots) I get an
>> error because of that. Have you tried the dev branch? `Pkg.checkout("Plots,
>> "dev")`, restart julia and re-run it.
>>
>> Scott
>>
>> On Monday, 14 November 2016 11:29:09 UTC, Ferran Mazzanti wrote:
>>>
>>> It is a minor variation of the example given by Scott
>>> for some data set y, cosy, y2, sqrty, siny, logy (doesn't matter the
>>> values, could be random)
>>>
>>> plot_1 = plot([y cosy],
>>>     title  = "Data y",
>>>     xlims  = (0,10),
>>>     ylims  = (-0.1,1.1),
>>>     grid   = true,
>>>     xlabel = "Iteration",
>>>     ylabel = "y & cos(y)"
>>> );
>>>
>>> plot_2 = plot(y2,
>>>     title  = "Data y Squared",
>>>     xlims  = (0,10),
>>>     ylims  = (-0.1,0.5),
>>>     grid   = false,
>>>     xlabel = "Iteration",
>>>     ylabel = "y^2",
>>>     legend = false,
>>> );
>>>
>>> plot_3 = plot( [sqrty siny],
>>> title  = "Square Root of y",
>>>     xlims  = (0,10),
>>>     ylims  = (-0.1,0.5),
>>>     grid   = false,
>>>     xlabel = "Iteration",
>>>     ylabel = "y^2"
>>> );
>>>
>>> plot_4 = plot(logy,
>>> title  = "Log of y",
>>>     xlims  = (0,10),
>>>     ylims  = (-10,0),
>>>     grid   = false,
>>>     xlabel = "Iteration",
>>>     ylabel = "y^2"
>>> );
>>>
>>> plot_5 = plot(expy,
>>> title  = "Exp of y",
>>>     xlims  = (0,10),
>>>     ylims  = (1,2),
>>>     grid   = false,
>>>     xlabel = "Iteration",
>>>     ylabel = "y^2"
>>> );
>>>
>>> lay = @layout [a grid(2,2); b]
>>> plot( plot_1, plot_2, plot_3, plot_4, plot_5, plot_5, layout = lay )
>>>
>>>

Reply via email to