get_order_plot

sherpa.astro.ui.get_order_plot(id=None, orders=None)

Return the data used by plot_order.

Parameters
  • id (int or str, optional) – The data set that provides the data. If not given then the default identifier is used, as returned by get_default_id.

  • orders (optional) – Which response to use. The argument can be a scalar or array, in which case multiple curves will be displayed. The default is to use all orders.

Returns

data – An object representing the data used to create the plot by plot_order.

Return type

a sherpa.astro.plot.OrderPlot instance

See also

get_default_id()

Return the default data set identifier.

plot_order()

Plot the model for a data set convolved by the given response.

Examples

Retrieve the plot information for order 1 of the default data set and then display it:

>>> oplot = get_order_plot(orders=1)
>>> print(oplot)

Return the plot data for orders 1 and 2 of data set ‘jet’, plot the first and then overplot the second:

>>> plots = get_order_plot('jet', orders=[1, 2])
>>> plots[0].plot()
>>> plots[1].overplot()