Closed cnrrobertson closed 2 months ago
I'm not 100% sure how to solve the problem, but maybe the answer is to manually set the colsizes to be equal in GridLayout's options? See here for accepted options: https://docs.makie.org/stable/explanations/specapi/#advanced_spec_layouting
The other thing - at least for /
, this might be expected behaviour? I would have to go back and use R's patchwork, but a/b/c resulting in two quarter-height plots and one half-height plot feels correct to me. We could implement plot_layout
in order to allow users to change that default once the configuration of the plots is correct
Sorry, had some testing imports leftover that broke the Github Action. Should be ready now.
I’ll merge this on the weekend - apparently there are merge conflicts and I don’t want to try to resolve them on my phone!
This PR extends the patchwork functionality from #61 for arbitrary numbers of
GGPlots
andGGPlotGrids
. It adds tests and docs for these as well.Although it's all working pretty well, there does seem to be one hiccup that I'm not sure how to overcome. In summary, we can do more than two operations with
+
simultaneously but not with|
or/
. i.e.plot + plot + plot
gives 3 side by side plots of equal width whereasplot | plot | plot
has two of 1/4 width and one of1/2
. This is effectively because the+
operator works with variable number of arguments while the|
,/
process one by one. I'm not sure how to get around this as it has to do with how the operator expression is parsed.You can explore this by looking at the difference between
Meta.parse("1 + 2 + 3").args
andMeta.parse("1 | 2 | 3").args
.