[yt-dev] Improved MultiPlot Support

Nathan Goldbaum nathan12343 at gmail.com
Sat Aug 13 19:20:19 PDT 2016


On Sat, Aug 13, 2016 at 9:09 PM, Gilbert, Austin B <agilbert39 at gatech.edu>
wrote:

> Hey all,
>
>    Looking at the current docs, generating a single figure from multiple
> plots is currently a bit of a hassle for the user. This is primarily
> because the method for doing so generates the figure from the bottom up
> --all of the axes and the figure are instantiated and then the user further
> manipulates them. I would like to add a multi plot container class that
> would reach this same end but takes a top down approach. Essentially users
> would input a list of yt plots or a nested list of yt plots, which
> simultaneously gives the container all of the plots and tells it how to
> layout the plots on the figure. From here the class would pull out the axes
> for each plot and then deposit them onto the single figure. Before I get
> into writing out the class I am looking for support as well as input. The
> main downside I see to this object is that the input needed to instantiate
> it will either need to be extremely specific or we will need to accept
> blank spaces in the resulting figure. Also, we would need to define a
> default behavior for laying out plots that display information from
> multiple fields. Thoughts and suggestions?
>

Hi Austin,

In principle I'm for this, but I think we need to be careful to get this
right, otherwise we might end up just making the situation more confusing.

There's definitely quite a bit of prior art here:

Manual plots based on matplotlib's AxesGrid and PotWindow's private
_setup_plots function:

http://yt-project.org/doc/cookbook/complex_plots.html#multipanel-with-axes-labels

get_multi_plot, which predates and is completely separate from PlotWindow
and was originally written for PlotWindow's predecessor, PlotCollection:

http://yt-project.org/doc/cookbook/complex_plots.html#multi-plot-slice-and-projections

The EPS writer:

http://yt-project.org/doc/visualizing/plots.html#publication-ready-figures

If we're going to do this, we need to make sure that whatever we come up
with subsumes all the use cases for the existing multi-plot examples in the
codebase and the docs, and hopefully end up with something that's better
and easier to use.

I think we need to decide how flexible we want this capability to be. i.e.
which kinds of plots can go into a given multi-panel plot, how do you
specify the multipanel plot, and how should it appear in the end.

This is a big enough project that I'd encourage you to write up a YTEP.
That will allow you to fully specify your design, put it in the context of
the existing multi-panel plotting capability in yt, and allow us to provide
input before you spend a lot of time writing code.

-Nathan


>
> Thanks,
>
> Austin Gilbert
>
> _______________________________________________
> yt-dev mailing list
> yt-dev at lists.spacepope.org
> http://lists.spacepope.org/listinfo.cgi/yt-dev-spacepope.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.spacepope.org/pipermail/yt-dev-spacepope.org/attachments/20160813/bfc30e73/attachment.htm>


More information about the yt-dev mailing list