|
|
Max-Planck-Institut für extraterrestrische Physik XMM-Newton Data Analysis - Example |
||||
| | |||||
|
|
| Data Analysis | Data Preparation | EPIC PN data | EPIC MOS data | RGS data | OM data | Get test data
Often it is functional to create a new events file that only contains events fulfilling certain criteria, e.g. they are in a given time interval or in a specified energy range. All examples given here are based on EPIC PN data and are done by the XMMSAS task evselect. This task needs the following paramteres to create a filtered event file:
evselect table=input-file
withfilteredset=true destruct=yes keepfilteroutput=true
expression="your selection criteria"
filteredset=output-file
where table means the input file, withfilteredset=true destruct=yes keepfilteroutput=true are all necessary to get an output filtered event file expression is the expression what you want to select, and filteredset is finally the name of your output file, the file you want to create. When you select events with the task evselect by using the parameter `expression', be sure not to put any 0 in front of the number you want to select. E.g., if you want to select all events with a PI channel number greater than 500, write it as given as in the example below. Do not use PI.gt.0500 instead!. Evselect will interpret the number 0500 not in the decimal system, it will take it as an octal number, in our example instead of having channel 500 you will get channel 5x64=320. Be aware of that! The task that filter events files according to the selection of events by special properties is described on the basis of four examples:
In this example we want to select events coming only from individual detector pixels (single events). There are two columns in the standard events file that characterize the pattern of an event, PATTERN and PAT_ID. If an event was a single in both columns the value will be 0. To select events which are distributed of two or three detector pixels (double or triple events) from the standard events file it is more complicated because it is coded in binary format. Here is the example for the single events: evselect table=events.fits withfilteredset=true destruct=yes keepfilteroutput=true \ expression="PATTERN.eq.0" filteredset=events_pat.fits 2. Select events by energy range Select events from an energy range between 0.5 and 5.0 keV. In this case the information about the energy is taken from the column PI of the events files. evselect table=events.fits withfilteredset=true destruct=yes keepfilteroutput=true \ expression="PI.gt.500 .and. PI.lt.5000" filteredset=events_energy.fits 3. Select events by spatial region Select all events detected in a circle with the radius 1200 sky pixels around a source with sky coordinates (X0 = 26025, Y0 = 26125). Here the selection is done according to column X and Y. evselect table=events.fits withfilteredset=true destruct=yes keepfilteroutput=true \ expression="circle(26025,26125,1200,X,Y)" filteredset=events_source.fits 4. Select events by time interval Select all events falling into the spacecraft clock time interval [65570000 s, 65580000 s] according to their arrival times stored in column TIME. evselect table=events.fits withfilteredset=true destruct=yes keepfilteroutput=true \ expression="TIME.gt.65570000 .and. TIME.lt.65580000" filteredset=events_time.fits 5. Select Good Time Intervals from a GTI file Select all times that are listed in the Good Time Interval (GTI) file. In our example the GTI file gti.fits has been created from an histogram file as described on the GTI Creation page. evselect table=events.fits withfilteredset=true destruct=yes keepfilteroutput=true \ expression="GTI(gti.fits,TIME" filteredset=events_gti.fits Comment Of course, also combinations of these selections are possible, e.g. Select all events in the time interval [65570000 s, 65580000 s] in the circle of 200'' around the source:
evselect table=events.fits withfilteredset=true destruct=yes keepfilteroutput=true \
expression="TIME.gt.65570000 .and. TIME.lt.65580000 .and. circle(26025,26125,4000,X,Y)" \
filteredset=events_filter.fits
| ||||