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

Jump to: Description · Examples · Bugs · See Also

AHELP for CIAO 4.3 Sherpa v1


Context: plotting


Changes the plot Y axis to use a linear scale.




The set_ylinear() command sets the scale of the Y axis of a specified plot to use linear scale. It is issued before generating the desired plot; i.e., the command will not alter a plot which has already been created. Once the command has been issued for a specific plot - e.g., for all fit plots with 'set_ylinear("fit")' - it will remain in effect for all such plots created in the current Sherpa session. The set_ylinear command accepts argument values similar to the generic Sherpa plot() function (see "ahelp plot"), e.g., "data", "model", "source", "fit", "delchi", etc. When called with no arguments, the Y axis of all plots created in the current Sherpa session will be set to use log scale. The Sherpa function set_xlinear behaves similarly for the X axis of plots. To set plot axes to linear scale, use the set_xlinear() and set_ylinear() commands. Note that the set_*log() and set_*linear() commands behave similarly to the ChIPS get_data_plot_prefs() and log_scale()/lin_scale() commands.

  • plot - the type of plot: arf, bkg, bkgchisqr, bkgdelchi, bkgfit, bkgmodel, bkgratio, bkgresid, bkgsource, chisqr, data, delchi, fit, kernel, model (convolved source model), psf, ratio, resid, or source (unconvolved source model).

Example 1

sherpa> set_ylinear()
sherpa> plot_data()

Set the Y axis of all plots created in the current Sherpa session to linear scale. Plot default data set 1 with a linearly scaled Y axis.

Example 2

sherpa> set_xlog()
sherpa> set_ylog()
sherpa> set_xlinear("model")
sherpa> plot("model", 2)

Display all plots created in the current Sherpa session in log scale, except the X axis of model plots; these should be in linear scale. Plot the model associated with data set 2, with the X axis in linear scale and the Y axis in log scale.


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

See Also

get_data_prof, get_data_prof_prefs, 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
copy_data, dataspace1d, dataspace2d, delete_data, fake, get_arf_plot, get_axes, get_bkg_plot, get_counts, get_data, get_data_plot, get_dep, get_dims, get_error, get_quality, get_specresp, get_staterror, get_syserror, group_sherpa, load_ascii, load_data, load_grouping, load_quality, set_data, set_quality, ungroup, unpack_ascii, unpack_data
get_filter, load_filter, set_filter
get_default_id, list_data_ids, list_response_ids
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_ylog
save_error, save_filter, save_grouping, save_quality, save_staterror, save_syserror
get_chisqr_plot, get_delchi_plot
calc_data_sum, calc_data_sum2d, calc_ftest, calc_kcorr, calc_mlr, calc_model_sum2d, calc_source_sum2d, get_rate
contour, contour_data, contour_ratio, contour_resid, get_ratio, get_resid, histogram1d, histogram2d, image_data, rebin

Last modified: December 2010
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.