[yt-users] writing to a file

Stephanie Tonnesen stonnes at gmail.com
Thu Jul 6 21:44:55 PDT 2017


Hi all,

I am trying to write a bunch of information from a gas-only single enzo
output to a file for colleagues to read.  I don't think they are familiar
with HDF5, so I am hoping to write to a fits file.  What I want to put in
the file is the x,y,z coordinates, the x,y,z velocity, and the total energy
of the gas--which is a user-defined function in my case.  Ideally I also
only want to include gas that has a tracer fraction of some value.

so basically I have something like:

ds = yt.load("file")
galgas = ds.cut_region(["obj['Metal_Density']/obj['density'] > 0.1"])

can I just create an array of the fields I want from galgas?

Thanks,
Stephanie

--
Dr. Stephanie Tonnesen
Alvin E. Nashman Postdoctoral Fellow
Carnegie Observatories, Pasadena, CA
stonnes at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.spacepope.org/pipermail/yt-users-spacepope.org/attachments/20170706/fc1da627/attachment.htm>


More information about the yt-users mailing list