About Chandra Archive Proposer Instruments & Calibration Newsletters Data Analysis HelpDesk Calibration Database NASA Archives & Centers Chandra Science Links

Skip the navigation links
Last modified: December 2006

URL: http://cxc.harvard.edu/ciao3.4/tgidselectsrc.html
Hardcopy (PDF): A4 | Letter
AHELP for CIAO 3.4 tgidselectsrc Context: tools

Synopsis

Filter an input source list based upon a SNR threshold.

Syntax

tgidselectsrc infile outfile snr_ratio_limit [setsrcid] [clobber]
[verbose]

Description

Filter an input source list based upon a SNR ratio threshold. `tgidselectsrc' filters the input file based upon a comparison of the ratio of each sources SNR to the first sources SNR with a threshold input by the user. It is expected that the source file is sorted on SNR, so that the source with the highest SNR is the first. The format of the output file is defined by that of the input file. In addition, if the input file had a TG_SRCID column, or if the user sets setsrcid to yes, then source ids will be calculated for each source and written to the output file. If the input file had a TG_SRCID column the source ids will be reset even if the user set setsrcid to no.

The input file must contain a column labelled SNR. The output file name will have an extension name of SRCLIST.

This tool is called by tgdetect and is not normally run independently.

To detect multiple sources with tgdetect, the snr_ratio_limit must be set below 1.0.

If there are any errors the task will return -1 and print the errors that occurred to the screen. Otherwise zero will be returned.

ALGORITHMS:

SNR Ratio filtering:

if SNR[i]/SNR[1] >= SNR ratio limit then the source[i] is good

This is done for all sources, 1 -> N. Obviously, the first source will always pass, as the maximum allowed value of the SNR limit is 1.0.

Example

tgidselectsrc $INDATA/tgselectsrc_src.fits . 0.95 setsrcid=yes
clobber=yes verbose=4

Process the sources in tgselectsrc_src.fits and use the infile as template for outfile name, set the limit to find sources down to half the SNR of the brightest source.

Parameters

name type ftype def min max reqd autoname
infile file input       yes  
outfile file output       yes yes
snr_ratio_limit real   1.0 0.0 1.0 yes  
setsrcid boolean   yes        
clobber boolean   no        
verbose integer   0        

Detailed Parameter Descriptions

Parameter=infile (file required filetype=input default=)

Name of input source table.

Parameter=outfile (file required filetype=output default= autoname=yes)

Name of output filtered source file

Parameter=snr_ratio_limit (real required default=1.0 min=0.0 max=1.0)

Value of SNR ratio to use as lower limit for sources output.

Parameter=setsrcid (boolean default=yes)

Flag to specify whether to assign sequential integer source identifiers to sources selected. (primarily for source-matching between observation intervals by tgdetect).

Parameter=clobber (boolean default=no)

Overwrite existing output file, or don't.

Parameter=verbose (integer default=0)

Control amount of diagnostic chatter from none (0) to most (5).

CHANGES IN CIAO 3.3

Parameter File

The kernel parameter has been removed.

Bugs

See the bugs page for this tool on the CIAO website for an up-to-date listing of known bugs.

Hardcopy (PDF): A4 | Letter
Last modified: December 2006



The Chandra X-Ray Center (CXC) is operated for NASA by the Smithsonian Astrophysical Observatory.
60 Garden Street, Cambridge, MA 02138 USA.    Email: cxcweb@head.cfa.harvard.edu
Smithsonian Institution, Copyright © 1998-2004. All rights reserved.