Fantastic :-) Thank you (runs off to make pretty pictures now.....)<br><br>Libby<br><br><div class="gmail_quote">2009/11/13 David Collins <span dir="ltr"><<a href="mailto:dcollins@physics.ucsd.edu">dcollins@physics.ucsd.edu</a>></span><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi Libby (and everyone else)<br>
<br>
I've added a new module called  yt.extensions.clump_tools to the<br>
trunk.  This module has three functions that should make it easier to<br>
visualize your clumps.<br>
<br>
So Britton's Clump attaches the clump hierarchy to whatever you call<br>
find_clumps on.  This is somewhat like what Rosolowsky et al 2008 do<br>
with their Dendrograms.  Two of these functions (return_all_clumps and<br>
return_bottom_clumps) return flatten arrays of clumps from what<br>
find_clumps does.  The third function in the module (clump_list_sort)<br>
sorts the list for ease of plotting.<br>
<br>
So first you'll do something like<br>
region = pf.h.sphere( radius = 0.1, center = [0.5]*3)<br>
base = Clump(region, *args)<br>
find_clumps(base, *args)<br>
<br>
base then has children, each of which then also have children, etc.<br>
This second generation of children is more fun because you don't have<br>
to feed them but you still get to buy them fun toys.<br>
<br>
To plot the entire hierarchy, you'd do something like this<br>
all_clumps = clump_tools.return_all_clumps(base)<br>
sorted = clump_tools.clump_list_sort(all_clumps)<br>
p.modify["clumps"](sorted)<br>
<br>
If you only want to plot the single objects, more akin to what one<br>
would find from CLUMPFIND, then use<br>
clump_tools.return_bottom_clumps<br>
<br>
return_all_clumps also adds a number, parentnumber, and level to each clump.<br>
<br>
There are two additional routines in the module, which are the<br>
recursive functions.  Ignore them, just call the wrapper.<br>
<br>
Hope this helps!<br>
d.<br>
<div><div></div><div class="h5"><br>
<br>
On Mon, Nov 9, 2009 at 11:44 AM, Elizabeth Harper-Clark<br>
<<a href="mailto:h-clark@cita.utoronto.ca">h-clark@cita.utoronto.ca</a>> wrote:<br>
> Hi Guys,<br>
><br>
> I am (trying) to use the find_clumps routine to identify clumps in my data<br>
> and I would then like to visualize it. How do I get the data from the<br>
> find_clumps routine into the callback:  p.modify["clumps"]() so I can put it<br>
> on projections/slices? What should it then look like?<br>
><br>
> Many thanks,<br>
><br>
> Libby<br>
><br>
> --<br>
> Elizabeth Harper-Clark MA MSci<br>
> PhD Candidate, Astrophysics, UofT<br>
><br>
> <a href="http://www.astro.utoronto.ca/%7Eh-clark" target="_blank">www.astro.utoronto.ca/~h-clark</a><br>
> <a href="mailto:h-clark@cita.utoronto.ca">h-clark@cita.utoronto.ca</a><br>
> AIM: edphc1<br>
> MSN: <a href="mailto:edphc1@hotmail.com">edphc1@hotmail.com</a><br>
> Skype: eharperclark<br>
> Office phone: 416-978-5759<br>
><br>
</div></div><div class="im">> _______________________________________________<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>
<br>
<br>
<br>
</div><font color="#888888">--<br>
Sent from my Stone Tablet and carried by my Pterodactyl.<br>
</font><div><div></div><div class="h5">_______________________________________________<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>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Elizabeth Harper-Clark MA MSci<br>PhD Candidate, Astrophysics, UofT<br><br><a href="http://www.astro.utoronto.ca/~h-clark">www.astro.utoronto.ca/~h-clark</a><br>
<a href="mailto:h-clark@cita.utoronto.ca">h-clark@cita.utoronto.ca</a><br>AIM: edphc1<br>MSN: <a href="mailto:edphc1@hotmail.com">edphc1@hotmail.com</a><br>Skype: eharperclark<br>Office phone: 416-978-5759<br>