Chandra X-Ray Observatory
Skip to the navigation links
Last modified: December 2009

Jump to: Description · Example · Bugs · See Also

AHELP for CIAO 4.3 Sherpa v1


Context: contrib


The plot preferences for radial or elliptical profiles of imaging data.




The get_data_prof_prefs() command returns the preferences for plots of data created by the prof_data(), prof_fit(), prof_fit_resid(), and prof_fit_delchi() commands. Changing the values will not change existing plots, only new plots created after the change was made. For example

sherpa> get_data_prof_prefs()["xlog"] = True

will cause any new plots to use logarithmic scaling for the X axis. A list of all the preferences is given below.

Loading the routine

The routine can be loaded into Sherpa by saying:

from sherpa_contrib.profiles import *

Plot defaults

The following table lists the allowed keys and values for the object returned by get_data_prof_prefs().

Key Allowed values
xlog False, True
ylog False, True
yerrorbars False, True
errstyle "line" or "capped"
errcolor Any valid ChIPS color (e.g. "red")
errthickness 0.5 to 10
symbolstyle chips_circle, chips_cross, chips_diamond, chips_none, chips_plus, chips_square, chips_point_type, chips_uptriangle, chips_downtriangle
symbolcolor Any valid ChIPS color (e.g. "red")
symbolfill False, True
symbolsize 1 to 100
linecolor Any valid ChIPS color (e.g. "red")
linethickness 0.5 to 10
linestyle chips_solid, chips_dot, chips_noline, chips_longdash, chips_shortdash, chips_dotlongdash, chips_dotshortdash, chips_shortdashlongdash


sherpa> prefs = get_data_prof_prefs()
sherpa> prefs["xlog"] = True
sherpa> prefs["ylog"] = True
sherpa> prefs["symbolstyle"] = chips_circle
sherpa> prefs["symbolfill"] = True
sherpa> prefs["yerrorbars"] = False
sherpa> prof_data()
sherpa> prof_fit()

The preferences are set so that:

  • both the x and y axes are to be drawn using log scaling;
  • symbol are drawn as filled circles;
  • and the y errorbars are turned off.

Setting the get_data_prof_prefs values only affects plots made after the change; to change an existing plot you need to use ChIPS commands such as log_scale() and linear_scale(). Note that the data preferences are also used when creating the "fit" plot, so this plot will also use the new preference settings.


See the bugs pages on the Sherpa website for an up-to-date listing of known bugs.

See Also

get_data_prof, get_delchi_prof, get_delchi_prof_prefs, get_fit_prof, get_model_prof, get_model_prof_prefs, get_resid_prof, get_resid_prof_prefs, get_source_prof, get_source_prof_prefs, plot_chart_spectrum, prof_data, prof_delchi, prof_fit, prof_fit_delchi, prof_fit_resid, prof_model, prof_resid, prof_source, sherpa_profiles
get_arf_plot, get_bkg_plot
get_energy_flux_hist, get_photon_flux_hist, get_split_plot, plot, plot_arf, plot_bkg, plot_chisqr, plot_data, plot_delchi, plot_energy_flux, plot_fit, plot_model, plot_model_component, plot_order, plot_photon_flux, plot_ratio, plot_resid, plot_source, plot_source_component, set_xlinear, set_xlog, set_ylinear, set_ylog
get_chisqr_plot, get_delchi_plot

Last modified: December 2009
Smithsonian Institute Smithsonian Institute

The Chandra X-Ray Center (CXC) is operated for NASA by the Smithsonian Astrophysical Observatory. 60 Garden Street, Cambridge, MA 02138 USA.   Email: Smithsonian Institution, Copyright © 1998-2019. All rights reserved.