<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>Hi Munier,</div><div><br></div><div>I suspect that the projection of the particle field is zero in the locations that are colored white in your image.  This causes these regions to 'fall off' the bottom end of the logarithmic color bar.</div><div><br></div><div>I think you have two options.  One would be to use a linear colorbar.  You can do this following the instructions here: <a href="http://yt-project.org/doc/faq/index.html#how-do-i-modify-whether-or-not-yt-takes-the-log-of-a-particular-field">http://yt-project.org/doc/faq/index.html#how-do-i-modify-whether-or-not-yt-takes-the-log-of-a-particular-field</a></div><div><br></div><div>Another option would be to make the plot by hand using a FixedResolutionBuffer.  In this case you would make the projection object by hand, extract the raw image buffer using an FRB, and then make the plot manually using matplotlib.  There's an example in the yt docs that covers how to do this: <a href="http://yt-project.org/doc/visualizing/manual_plotting.html?highlight=manual plotting">http://yt-project.org/doc/visualizing/manual_plotting.html?highlight=manual%20plotting</a></div><div><br></div><div>In the latter case if you want the areas that project to zero to appear with a logarithmic colorbar, you'll need to manually set the regions in the FRB that are equal to zero to some small number.</div><div><br></div><div>Cheers,</div><div><br></div><div>Nathan</div><br><div><div>On Nov 28, 2012, at 9:29 AM, Munier Azzam Salem wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>Hi yt gurus,</div><div><br></div><div>      I've been making projections of star_density from enzo output files and they seem to be working out fine. However, wherever particles do not exist the background remains white instead of following my chosen colormap. Is there a way to paint these areas to follow the colormap?</div>
<div><br></div><div>       thanks!</div><div>           Munier</div><div><br></div>I've attached an image of what gets plotted, and the relevant bits of my script are:<div><br></div><div><div><font face="courier new, monospace"><b>from yt.mods import *</b></font></div>
<div><font face="courier new, monospace"><b><br></b></font></div><div><font face="courier new, monospace"><b>fName = "DD0006/test_sim_0006"</b></font></div><div><font face="courier new, monospace"><b>var   = "star_density"</b></font></div>
<div><font face="courier new, monospace"><b>axis  = 0</b></font></div><div><font face="courier new, monospace"><b><br></b></font></div><div><font face="courier new, monospace"><b>pf = load(fName)</b></font></div><div><font face="courier new, monospace"><b>pf.h</b></font></div>
<div><font face="courier new, monospace"><b><br></b></font></div><div><font face="courier new, monospace"><b>pc = PlotCollection(pf)</b></font></div><div><font face="courier new, monospace"><b>p = pc.add_projection(var,axis)</b></font></div>
<div><font face="courier new, monospace"><b>#p.modify["particles"](1.0)</b></font></div><div><font face="courier new, monospace"><b><br></b></font></div><div><font face="courier new, monospace"><b>radius = .02;</b></font></div>
<div><font face="courier new, monospace"><b><br></b></font></div><div><font face="courier new, monospace"><b>pc.set_xlim(.5-radius,.5+radius)</b></font></div><div><font face="courier new, monospace"><b>pc.set_ylim(.5-radius,.5+radius)</b></font></div>
<div><font face="courier new, monospace"><b><br></b></font></div><div><font face="courier new, monospace"><b>pc.save(fName)</b></font></div><div><br></div><div><br></div>-- <br>Munier A. Salem // 845.489.6450<br>
</div>
<span><test_sim_0006_Projection_x_star_density.png></span>_______________________________________________<br>yt-users mailing list<br><a href="mailto:yt-users@lists.spacepope.org">yt-users@lists.spacepope.org</a><br>http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org<br></blockquote></div><br></body></html>