|
|
load_data( [id], filename; [options] );
The load_data command is a filetype-independent method of
loading 1D data from a file (e.g. if the file-specific load
command is unknown or if the filetype is unknown). It tries
to load the file in the following order: load_pha,
load_table, and load_ascii.
-
id - the id of the dataset to use; if not given, uses the default dataset id (id=1 by default, see "ahelp get_default_id")
-
filename - the name of the file (with path) which contains
the data
If the filetype is known, file-specific options may be
included in the load_data command. They are:
-
load_pha: use_errors
-
load_table: ncols, colkeys, and dstype
-
load_ascii: ncols, colkeys, sep, comment, and dstype
Refer to the individual command ahelp files for specifics on
the options.
sherpa> load_data("data.filtered");
Using the default settings, load a data file into Sherpa.
sherpa> load_data("src", "data.txt"; ncols=3);
Load the first three columns of data.txt, using the
dataset id "src". This example could also have been done
using the load_ascii command.
sherpa> load_data("src", "source.pha");
Data is loaded from the file source.pha with data id
"src". This example could also have been done
using the load_pha command.
sherpa> load_data("rprofile_mid.fits[cols RMID,SUR_BRI,SUR_BRI_ERR]");
sherpa> load_data("rprofile_mid.fits";
colkeys=["RMID","SUR_BRI","SUR_BRI_ERR"]);
These commands are equivalent ways of loading x=RMID,
y=SUR_BRI, and staterror=SUR_BRI_ERR from
rprofile_mid.fits, a radial profile for which the midpoint
of the annular regions has been calculated. This example
could also have been done using the load_table command.
- py.sherpa
-
get_staterror,
get_syserror
- sl.sherpa
-
add_user_pars,
calc_data_sum,
calc_data_sum2d,
calc_ftest,
calc_kcorr,
calc_mlr,
calc_model_sum2d,
calc_source_sum2d,
clean,
contour,
contour_data,
contour_ratio,
copy_data,
dataspace1d,
dataspace2d,
delete_data,
get_axes,
get_bkg_plot,
get_counts,
get_data,
get_data_plot,
get_default_id,
get_dep,
get_dims,
get_error,
get_filter,
get_rate,
get_ratio,
get_resid,
get_specresp,
get_staterror,
get_syserror,
group,
histogram1d,
histogram2d,
image_data,
list_bkg_ids,
list_data_ids,
list_response_ids,
load_arf,
load_arrays,
load_ascii,
load_bkg,
load_bkg_arf,
load_bkg_rmf,
load_image,
load_multi_arfs,
load_multi_rmfs,
load_pha,
load_rmf,
load_table,
load_table_model,
load_user_model,
pack_image,
pack_pha,
pack_table,
plot_data,
rebin,
save_data,
save_image,
save_pha,
save_table,
set_data,
ungroup,
unpack_arf,
unpack_arrays,
unpack_ascii,
unpack_bkg,
unpack_data,
unpack_image,
unpack_pha,
unpack_rmf,
unpack_table
|