[yt-users] ProfilePlot(), How to write the plotted values to a file?

Britton Smith brittonsmith at gmail.com
Fri Apr 22 03:50:03 PDT 2016


Hi Reju,

If you are on the development version of yt, the plot object will have a
function associated with it called save_as_dataset.  This will write out a
file with the plot data and this file can be reloaded with yt.load.  Have a
look here for a full description of how to use it.
http://yt-project.org/docs/dev/analyzing/saving_data.html#spatial-plots

Britton

On Fri, Apr 22, 2016 at 8:57 AM, Reju Sam John <rejusamjohn at gmail.com>
wrote:

> Hi,
>
> I would like to know, how to write the plotted values of a 'ProfilePlot()'
> to a file? For example, I made a  histogram with the following line.
>  plot = ProfilePlot(sphere_200, "ProtonMomentum", ["NoOfProton"],
> weight_field="CellMass")
>
> But how can I write the values of "ProtonMomentum" and "NoOfProton" to a
> file?
>
> Thankyou.
>
> --
> Reju Sam John
>
> _______________________________________________
> 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/20160422/d120a9f4/attachment.html>


More information about the yt-users mailing list