[yt-users] setting limits on phase plots

meecegre at msu.edu meecegre at msu.edu
Fri Sep 2 13:04:45 PDT 2011


Hi Christine,
It looks like you're setting the limits using the exponent operator. I think what you want is

pc.set_zlim(1.0e-2, 1.0e5)
pc.set_xlim(1.0e-30, 5.0e-19)
pc.set_ylim(10.0, 1.0e7)

1.0e-2 is equivalent to 1.0 * 10^-2, which I think is what you're trying to do. Right now, yt is trying to set the zlim to be qual, and the min for the other two limits to be larger than the max, which could be causing it to go crazy.

Hope this helps!

--Greg

Quoting Christine Simpson <csimpson at astro.columbia.edu>:

> Hi all,
>
> I'm trying to make some phase plots and specify the x axis limits, the y
> axis limits and the color bar limits.  I've tried this:
>
> pc.add_phase_sphere(r200[j],'kpc',["Density","Temperature","CellMassMsun"],weight=None)
> pc.set_zlim(1.0**-2,1.0**5)
> pc.set_xlim(1.0**-30,5.0**-19)
> pc.set_ylim(10.0,1.0**7)
>
> It sets the limits to some random values and I get an empty plot.  I
> thought there was some 'redraw' callback that I could try and I tried
> 'pc.redraw()' and 'pc.redraw_image()', but I guess 'redraw' can only be
> used with interactive plot collections?
>
> Christine
>
> _______________________________________________
> yt-users mailing list
> yt-users at lists.spacepope.org
> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.spacepope.org/pipermail/yt-users-spacepope.org/attachments/20110902/eb5024c2/attachment.htm>


More information about the yt-users mailing list