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

Synopsis

Allows model parameter(s) to vary.

Syntax

sherpa> THAW <arg_1> [<arg_2> ...]

Description

<arg> may be:

THAW Command Arguments

Argument Description
<sherpa_modelname>.{<paramname> | <#>} Thaws the specified model component parameter.
<modelname>.{<paramname> | <#>} Thaws the specified model component parameter.
<sherpa_modelname> Thaws all parameters of the specified model component.
<modelname> Thaws all parameters of the specified model component.
<sherpa_model_stack> [# [ID]] Thaws the parameters of all model components within the specified model stack (SOURCE, BACKGROUND, PILEUP, [B]NOISE, or KERNEL). # is a dataset number (default 1); see BACKGROUND for an explanation of ID.
<model_stack> Thaws the parameters of all model components within the user-defined model stack.

The command FREEZE is used to prohibit model parameter values from varying.

In addition, model parameters may be thawed using the equivalent command

  • sherpa> <modelname>.{<paramname>|<#>}.TYPE = THAW

Model parameters may also be thawed using the Sherpa/S-Lang module functions set_thawed and set_par.

Example 1

Thaw a model parameter:

sherpa> GAUSS[modelb]
modelb.fwhm parameter value [10]
modelb.pos parameter value [0]
modelb.ampl parameter value [1]
sherpa> THAW modelb.ampl

The final command thaws the parameter ampl of modelb.

Example 2

Freeze a model parameter and thaw a model parameter:

sherpa> FREEZE modelb.3
sherpa> THAW modelb.3

First, the third parameter of modelb is frozen. The last command then thaws the third parameter of modelb.

Example 3

Freeze all model parameters and thaw two model parameters:

sherpa> FREEZE modelb
sherpa> THAW modelb.fwhm modelb.pos

First, all parameters of modelb are frozen. The last command then thaws the fwhm and pos parameters of modelb.

Example 4

Freeze or thaw all source component parameters at once:

sherpa> PARAMPROMPT OFF
Model parameter prompting is off
sherpa> POW[modelc]
sherpa> GAUSS[modelf]
sherpa> SOURCE 2 = modelc + modelf
sherpa> FREEZE SOURCE 2
sherpa> SHOW SOURCE 2
Source 2:

(modelc + modelf)
powlaw1d[modelc]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1  gamma frozen          1        -10         10
 2    ref frozen          1-3.4028e+38 3.4028e+38
 3   ampl frozen          1      1e-20 3.4028e+38
gauss1d[modelf]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1   fwhm frozen         10 1.1755e-38 3.4028e+38
 2    pos frozen          0-3.4028e+38 3.4028e+38
 3   ampl frozen          1-3.4028e+38 3.4028e+38
sherpa> THAW SOURCE 2
sherpa> SHOW SOURCE 2
(modelc + modelf)
powlaw1d[modelc]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1  gamma thawed          1        -10         10
 2    ref frozen          1-3.4028e+38 3.4028e+38
 3   ampl thawed          1      1e-20 3.4028e+38
gauss1d[modelf]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1   fwhm thawed         10 1.1755e-38 3.4028e+38
 2    pos thawed          0-3.4028e+38 3.4028e+38
 3   ampl thawed          1-3.4028e+38 3.4028e+38

This example illustrates the use of FREEZE SOURCE and THAW SOURCE to freeze and thaw all source component parameters at once, respectively. Note that thawing of some model parameters (e.g., POWLAW1D.ref) is not permitted.

Example 5

Thaw a model parameter:

sherpa> modelb.ampl.TYPE = THAW

This command thaws the parameter ampl of modelb. The following commands are each equivalent:

sherpa> modelb.3.TYPE = THAW
sherpa> THAW modelb.ampl
sherpa> THAW modelb.3

Example 6

Freeze all model parameters at once and thaw all source parameters at once:

sherpa> PARAMPROMPT OFF
Model parameter prompting is off
sherpa> DATA data/example.pha
sherpa> GAUSS[modelc]
sherpa> SOURCE = modelb + modelc
sherpa> FREEZE modelc
sherpa> SHOW SOURCE
(modelb + modelc)
gauss1d[modelb]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1   fwhm frozen          2 1.1755e-38 3.4028e+38
 2    pos frozen          0-3.4028e+38 3.4028e+38
 3   ampl thawed          1-3.4028e+38 3.4028e+38
gauss1d[modelc]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1   fwhm frozen     0.7113     0.0071    71.1283
 2    pos frozen     0.9442     0.0276    14.5494
 3   ampl frozen     0.0001 1.0564e-06     0.0106
sherpa> THAW SOURCE
sherpa> SHOW SOURCE
(modelb + modelc)
gauss1d[modelb]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1   fwhm thawed          2 1.1755e-38 3.4028e+38
 2    pos thawed          0-3.4028e+38 3.4028e+38
 3   ampl thawed          1-3.4028e+38 3.4028e+38
gauss1d[modelc]  (integrate: on)
    Param   Type      Value        Min        Max                 Units
    -----   ----      -----        ---        ---                 -----
 1   fwhm thawed     0.7113     0.0071    71.1283
 2    pos thawed     0.9442     0.0276    14.5494
 3   ampl thawed     0.0001 1.0564e-06     0.0106

Note that the command FREEZE modelc freezes all parameters of the source model component modelc, while THAW SOURCE thaws all parameters of both source model components.

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.