From an existing object, create a 2D, binned profile.
This function will accept an existing AMRData source and from that, it will generate a Binned2DProfile, based on the specified options. This is useful if you have extracted a region, or if you wish to bin some set of massages data – or even if you wish to bin anything other than a sphere. The profile will be 2D, which means while it can have an arbitrary number of fields, those fields will all be binned based on two fields.
Parameters : | data_source : yt.lagos.AMRData
fields : list of strings
cmap : string, optional
weight : string, default “CellMassMsun”
accumulation : list of booleans, optional
x_bins : int, optional
x_log : boolean, optional
x_bounds : tuple of floats, optional
y_bins : int, optional
y_log : boolean, optional
y_bounds : tuple of floats, optional
lazy_reader : boolean, optional
id : int, optional
figure : matplotlib.figure.Figure, optional
axes : matplotlib.axes.Axes, optional
fractional : boolean
|
---|---|
Returns : | plot : yt.raven.PlotTypes.PhasePlot
|
See also
Examples
This will show the mass-distribution in the Density-Temperature plane.
>>> pf = load("RD0005-mine/RedshiftOutput0005")
>>> reg = pf.h.region([0.1, 0.2, 0.3], [0.0, 0.1, 0.2],
... [0.2, 0.3, 0.4])
>>> pc.add_phase_object(reg, ["Density", "Temperature", "CellMassMsun"],
... weight = None)