|AHELP for CIAO 4.5 Sherpa v1||
Apply an include filter to 1D data by dataset id
notice_id( ids, [lo,hi,bkg_id] ) notice_id( ids, expr, bkg_id )
The notice_id command specifies the portion of 1D data to be included in the analysis. The filter is applied to the specified dataset ids; to operate on all datasets without having to list the ids, use the notice command ("ahelp notice").
When a filter is applied to a source data set, it is also automatically applied to all associated background data sets. A different filter for a background can still be imposed afterward, using the bkg_id parameter to filter just the background.
- ids - a list of ids of the data sets to filter; default=None
- bkg_id - background data set ID, to apply a separate filter to associated background data (when left blank, the background will be filtered automatically according to the specified source filter; see 'id' description above)
- lo: lower bound of the filter; default=None
- hi: upper bound of the filter; default=None
- expr: a filter expression to notice an intersection of filters, e.g. "0.1:5, 6:7". Range filtering allows ":#" and "#:", which includes an open-ended range of data up to or beginning at the given value (#), respectively.
The units for the limits are determined by the "units" field of the data structure: channels, energy (keV), or wavelength (angstrom). The value can be obtained by using the get_analysis command ("ahelp get_analysis").
If no limits are supplied, all data points in the specified datasets are included. Noticing the entire set is a method of clearing any filters that have been applied. It is also possible to specify just a lower limit or just an upper limit; the unspecified value will remain at the data minimum or maximum.
If the data is binned and the endpoint of the interval falls within a bin, the entire bin is included in the filter.
sherpa> notice_id(1, 5000,7000, bkg_id=2)
Ignore all data points below channel 5000 and above 7000 in the second backround data set associated with source data set 1.
The command is called without any limits defined, so all data points in datasets 1 and 2 are included.
sherpa> notice_id("src", 1.0, 6.0)
Include only data in the 1.0-6.0 keV range in the dataset labeled "src".
sherpa> notice_id(2, "0.1:5, 6:7")
Notice the bins in dataset 2 between 0.1 and 5 keV and between 6 and 7 keV.
sherpa> notice_id(2, 200,) sherpa> notice_id(2, 200, None)
These commands are two equivalent ways of applying an open-ended notice_id filter to data set 2, in channel space. The lower limit of the filter is set at channel 200, but the upper limit is undefined so that all data above channel 200 is included in the analysis.
sherpa> notice_id([2,4], , 8.0) sherpa> notice_id([2,4], None, 8.0)
These commands are two equivalent ways of applying an open-ended notice_id filter to data sets 2 and 4 in energy space. The lower limit of the filter is undefined and the upper limit is set to 8.0 keV, so that all data below 8.0 keV is included in the analysis.
See the bugs pages on the Sherpa website for an up-to-date listing of known bugs.