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/setdata.html
Hardcopy (PDF): A4 | Letter
AHELP for CIAO 3.4 setdata Context: sherpa

Synopsis

Sets attributes of a source dataset.

Syntax

sherpa> SETDATA [#] <arg> = <numeric>

where # specifies the number of the background dataset (default dataset
number is 1).

Description

The argument <arg> is one of the following options:

SETDATA Command Arguments

Argument Description
BACKSCALE A normalizing quantity which can indicate the the ratio of the area of the source extraction region in an image to the full image area.
TIME The exposure time of the source observation.

The primary use of this command is to set the attributes of non-PHA datasets (e.g. ASCII datasets). Setting TIME affects the normalization of the source model, which is entered with the SOURCE command.

Setting BACKSCAL affects the relative normalization of the background model when it is applied to a source region. For instance, if the background model amplitude in a background dataset bin is M_B, the BACKSCAL of that dataset is B_B, and the BACKSCAL of the source dataset is B_S, then the contribution of the background to the source region spectrum is

M_B' = (B_S/B_B) * M_B

For related information, see SETBACK.

Example 1

Set the time of an input ASCII dataset:

sherpa> READ DATA example1.dat
sherpa> PARAMPROMPT OFF
sherpa> SOURCE = POLY[p]
sherpa> THAW p.c1 p.c2
sherpa> FIT
 LVMQT: V2.0
 LVMQT: initial statistic value = 325.453
 LVMQT: final statistic value = 0.255412 at iteration 2
             p.c0  0.305218     
             p.c1  -0.142263     
             p.c2  1.01643     

sherpa> SETDATA TIME = 100
sherpa> FIT
 LVMQT: V2.0
 LVMQT: initial statistic value = 1.43934e+06
 LVMQT: final statistic value = 0.255412 at iteration 3
             p.c0  0.00292297     
             p.c1  -0.00133705     
             p.c2  0.0101542     

Example 2

Set the times and backscales for an input dataset with mean amplitude 60 counts and a background dataset with mean amplitude 20 counts:

sherpa> DATA spec.dat
sherpa> BACK back.dat
sherpa> PARAMPROMPT OFF
sherpa> SOURCE = CONST[co]
sherpa> BG = CONST[bo]
sherpa> FIT
 LVMQT: V2.0
 LVMQT: initial statistic value = 980.167
 LVMQT: final statistic value = 142.424 at iteration 3
            co.c0  39.3331     
            bo.c0  18.4647     

sherpa> SETDATA TIME = 10
sherpa> SETDATA BACKSCALE = .1
sherpa> SETBACK TIME = 100
sherpa> SETBACK BACKSCALE = .25
sherpa> bo.c0.min = 0
sherpa> FIT
 LVMQT: V2.0
 LVMQT: initial statistic value = 7.34745e+07
 LVMQT: final statistic value = 142.424 at iteration 3
            co.c0  5.70591     
            bo.c0  0.0738588     

Bugs

See the Sherpa bug pages online 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.