Synopsis
Include a spatial region of a data set.
Syntax
notice2d_id(ids, val=None)
Description
Select a spatial region to include in the fit. The filter is applied to the given data set, or sets.
Examples
Example 1
Select all the pixels in the default data set:
>>> notice2d_id(1) dataset 1: Circle(100,45,10) -> Field()
Example 2
Select all the pixels in data sets 'i1' and 'i2':
>>> notice2d_id(['i1', 'i2'])
Example 3
Apply the filter to the 'img' data set:
>>> notice2d_id('img', 'annulus(4324.2,3982.2,40.2,104.3)') dataset 1: Field() -> annulus(4324.2,3982.2,40.2,104.3)
Example 4
Use the regions in the file `srcs.reg` for data set 1:
>>> notice2d_id(1, 'srcs.reg')
or
>>> notice2d_id(1, 'region(srcs.reg)')
PARAMETERS
The parameters for this function are:
Parameter | Type information | Definition |
---|---|---|
ids | int or str, or array of int or str | The data set, or sets, to use. |
val | str, optional | A region specification as a string or the name of a file containing a region filter. The coordinates system of the filter is taken from the coordinate setting of the data sets ( `set_coord` ). If none , then all points are included. |
Notes
The region syntax is described in the `notice2d` function.
Changes in CIAO
Changed in CIAO 4.15
The change in the filter is now reported for the dataset.
Bugs
See the bugs pages on the Sherpa website for an up-to-date listing of known bugs.
See Also
- data
- group, group_adapt, group_adapt_snr, group_bins, group_counts, group_snr, group_width
- filtering
- get_filter, ignore, ignore2d, ignore2d_id, ignore_bad, ignore_id, notice, notice2d, notice_id, show_filter