<div dir="ltr"><div><div><div>Hi Matt,<br></div>many thanks for a prompt response. The output looks like this. <br></div>print np.unique(dd["particle_type"])<br>[1 5]<br>
print np.unique(dd["creation_time"]).size<br>2586<br>
 It seems particle type is 5 which i assumed to be 2.  </div>Cheers<br>Latif<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, May 14, 2013 at 1:45 PM, Matthew Turk <span dir="ltr"><<a href="mailto:matthewturk@gmail.com" target="_blank">matthewturk@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Tue, May 14, 2013 at 7:21 AM, Latif <<a href="mailto:latifne@gmail.com">latifne@gmail.com</a>> wrote:<br>

> Hi all,<br>
> I have star particles in enzo simulations.  Counting the particles by<br>
> creation time and type gave different results. Is it a problem with Yt or<br>
> comes from simulation? Any ideas?<br>
><br>
> star_particles = dd["creation_time"] > 0.0<br>
> print "Number of star particles by creation time", star_particles.sum()<br>
> star_particles = dd["particle_type"] == 2<br>
> print "Number of star particles by type", star_particles.sum()<br>
><br>
><br>
> Number of star particles by creation time 3818<br>
> Number of star particles by type 0<br>
<br>
</div></div>What's the output of<br>
<br>
print np.unique(dd["particle_type"])<br>
print np.unique(dd["creation_time"]).size<br>
<br>
?<br>
<br>
-Matt<br>
<div class="im"><br>
><br>
> thanks in advance,<br>
> Cheers<br>
> Latif<br>
><br>
</div>> _______________________________________________<br>
> yt-users mailing list<br>
> <a href="mailto:yt-users@lists.spacepope.org">yt-users@lists.spacepope.org</a><br>
> <a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
><br>
_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
</blockquote></div><br></div>