[yt-users] time_series_phase plots & missing color bars

John Wise jwise at astro.princeton.edu
Sun Aug 1 08:51:25 PDT 2010


On 1 Aug 2010, at 02:09, Robert Thompson wrote:

> Hello fellow yt users!
> 
> I'm new at yt and have been working through the cookbook for a few days now.  So far I've got 2 issues that I cannot resolve.  I'm trying to make Phase diagrams (using time_series_phase.py form the cookbook), and I'm getting the following error on the SDSC cluster Triton (who's environment & installations were set up by Matt Turk):

[snip]

> My second issue is that I'm not getting color bars when making multiplots through the use of multi_plot.py.  Here is the script (slightly altered from the cookbook) I am using:
> 
> from yt.mods import * # set up our namespace                                        
> orient = 'horozontal'
> for i in range(0,27):
>     fn = "RD%04i/RedshiftOutput%04i" % (i,i) # parameter file to load               
>     pf = load(fn) # load data                                                       
>     fig, axes, colorbars = raven.get_multi_plot(3, 1, colorbar=orient, bw=4)
>     pc = PlotCollection(pf, center=[0.5,0.5,0.5])
>     p = pc.add_projection("Density", 0, figure=fig, axes = axes[0][0], use_colorbar\
> =False)
>     pc.set_cmap("bds_highcontrast")
>     p = pc.add_projection("Temperature", 0, figure=fig, axes=axes[0][1], use_colorb\
> ar=False)
>     p = pc.add_projection("particle_density_pyx", 0, figure=fig, axes=axes[0][2], u\
> se_colorbar=False)
>     for p, cax in zip(pc.plots, colorbars):
>         cbar = cb.Colorbar(cax, p.image, orientation=orient)
>         p.colorbar = cbar
>         p._autoset_label()
>     fig.savefig("%s_projection" % pf)

Hi Robert,

I don't know how to solve your first problem, but I see the problem in your second issue.  You misspelled 'horizontal'.  So I think that'll solve your missing colorbar problem.

John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.spacepope.org/pipermail/yt-users-spacepope.org/attachments/20100801/5f033f42/attachment.html>


More information about the yt-users mailing list