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

Synopsis

Automatic estimation of initial parameter values in Sherpa models

Description

It is important to note that when a model component is established, if a dataset has been input, then estimates based on the (filtered) data are automatically made for the initial parameter values and their minimum and maximum ranges. However, if no dataset has been input, then the initial parameter values and ranges are assigned arbitrary default values.

If multiple datasets have been input, and if no dataset is indicated in the model expression, then automatic parameter estimates are based on the lowest numbered dataset; for instance, if the user inputs


sherpa> DATA 1 example1.dat
sherpa> DATA 2 example2.dat
sherpa> POLY[modela]

then the estimates of modela's parameter values are based on the first dataset. Otherwise, if multiple datasets have been input, and a dataset is indicated in the model expression, then the automatic parameter estimates are made based on the indicated dataset; for instance, if the user inputs


sherpa> DATA 1 example1.dat
sherpa> DATA 2 example2.dat
sherpa> SOURCE 2 = POLY[modela]

then the estimates of modela's parameter values are based on the second dataset.

The user may always obtain updated estimates using the command GUESS. Updated estimates may be needed if:

  • a dataset is input,
  • or an instrument model is specified,
  • or a dataset filter is changed,
  • or a dataset COORD analysis setting is changed,

after a model expression is input.

The user may of course wish to directly set initial parameter values and ranges; see the CREATE command.

Example 1

Establish a model component prior to data input:


sherpa> ERASE ALL
sherpa> POW[modelc]
modelc.gamma parameter value [1] 
modelc.ref parameter value [1] 
modelc.ampl parameter value [1] 
sherpa> SHOW modelc
powlaw1d[modelc]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1  gamma thawed          1        -10         10                      
 2    ref frozen          1 -3.403e+38 3.4028e+38                      
 3   ampl thawed          1          0 3.4028e+38                      

Here, a model component is established prior to input of data, so the given initial model parameter values are pre-set arbitrary defaults. In this example, the user accepts these values using the <RETURN> key.

Example 2

Establish a model component after data input:


sherpa> ERASE ALL
sherpa> DATA example.pha
...
sherpa> POW[modelc]
modelc.gamma parameter value [1] 
modelc.ref parameter value [1] 
modelc.ampl parameter value [1.08261e-05] 
sherpa> SHOW modelc
powlaw1d[modelc]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1  gamma thawed          1        -10         10                      
 2    ref frozen          1 2.7614e-02    14.5494                      
 3   ampl thawed 1.0826e-05 1.0826e-07 1.0826e-03                      

In this example, the ERASE ALL command is used to remove the previous model setup. Next, data are input, with the command DATA example.pha. This is then followed by the establishment of the model component, with the command POW[modelc]. Notice that the given initial model parameter values and ranges are estimates based on the filtered data.

Example 3

Establish a model component prior to data input; obtain parameter estimates using GUESS:


sherpa> ERASE ALL
sherpa> POW[modelc]
modelc.gamma parameter value [1]
modelc.ref parameter value [1]
modelc.ampl parameter value [1]
sherpa> DATA example.pha
...
sherpa> SHOW modelc
powlaw1d[modelc]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1  gamma thawed          1        -10         10                      
 2    ref frozen          1 -3.403e+38 3.4028e+38                      
 3   ampl thawed          1          0 3.4028e+38                      
sherpa> GUESS modelc
sherpa> SHOW modelc
powlaw1d[modelc]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1  gamma thawed          1        -10         10                      
 2    ref frozen          1 2.7614e-02    14.5494                      
 3   ampl thawed 1.0826e-05 1.0826e-07 1.0826e-03                      

In this example, the ERASE ALL command is used to remove the previous input data and model component setups. Next, a model component is established prior to input of data (with the command POW[modelc]), and so the given initial parameter values are default values. The GUESS command is then used to obtain parameter value and range estimates, based on the input dataset.

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.