ProfilePlot(), How to write the plotted values to a file?
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
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
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@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
Thank you very much, Britton. But I am facing a problem. We were using YT
2.6.
For getting the above facility, I am converting my code to YT 3.3 dev
compatible. Unfortunately, I am unable to find a field, which is
equivalent to the *'CellMass' *of YT 2.6. How to get the Baryonic mass
information of a Cell?
Thankyou.
On Fri, Apr 22, 2016 at 4:20 PM, Britton Smith
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
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@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- Reju Sam John
You're looking for the 'cell_mass' field.
On Saturday, April 23, 2016, Reju Sam John
Thank you very much, Britton. But I am facing a problem. We were using YT 2.6. For getting the above facility, I am converting my code to YT 3.3 dev compatible. Unfortunately, I am unable to find a field, which is equivalent to the *'CellMass' *of YT 2.6. How to get the Baryonic mass information of a Cell?
Thankyou.
On Fri, Apr 22, 2016 at 4:20 PM, Britton Smith
javascript:_e(%7B%7D,'cvml','brittonsmith@gmail.com');> wrote: 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
javascript:_e(%7B%7D,'cvml','rejusamjohn@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@lists.spacepope.org javascript:_e(%7B%7D,'cvml','yt-users@lists.spacepope.org'); http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org javascript:_e(%7B%7D,'cvml','yt-users@lists.spacepope.org'); http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- Reju Sam John
Thank-you very much.. :-)
On Sat 23 Apr, 2016, 7:09 PM Nathan Goldbaum,
You're looking for the 'cell_mass' field.
On Saturday, April 23, 2016, Reju Sam John
wrote: Thank you very much, Britton. But I am facing a problem. We were using YT 2.6. For getting the above facility, I am converting my code to YT 3.3 dev compatible. Unfortunately, I am unable to find a field, which is equivalent to the *'CellMass' *of YT 2.6. How to get the Baryonic mass information of a Cell?
Thankyou.
On Fri, Apr 22, 2016 at 4:20 PM, Britton Smith
wrote: 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
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@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- Reju Sam John
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
participants (3)
-
Britton Smith
-
Nathan Goldbaum
-
Reju Sam John