treeparameter - Manipulate and query tree parameters. |
treeparameter -create name low high units treeparameter -list [pattern] treeparameter -set name bins low high inc units treeparameter -setinc name inc treeparameter -setbins name bins treeparameter -setunit name units treeparameter -setlimits name low high treeparameter -check name treeparameter -uncheck name treeparameter -version
The treeparameter command is part of the Tree Parameter package. The command allows users or scripts to list or modify characteristics of the defined treeparameters.
treeparameter -create new.tree.parameter -1.0 1.0 100 mm
This subcommand lists the properties of the known tree parameters. The optional pattern parameter allows you to specify a glob pattern that will restrict the set of parameters that are listed. glob patterns are strings that have the same wildcard characters supported by filesystem matching in unix.
The output is a well-formed TCL list. Each element of the list is in turn a well formed sublist that describes a single parameter. Elements of the sublist are, in order;
treeparameter -list {event.raw.00 100 1 100 0.99 channels} {event.raw.01 100 1 100 0.99 channels} {event.raw.02 100 1 100 0.99 channels} {event.raw.03 100 1 100 0.99 channels} {event.raw.04 100 1 100 0.99 channels} {event.raw.05 100 1 100 0.99 channels} {event.raw.06 100 1 100 0.99 channels} {event.raw.07 100 1 100 0.99 channels} {event.raw.08 100 1 100 0.99 channels} {event.raw.09 100 1 100 0.99 channels} {event.sum 100 1 100 0.99 arbitrary}
treeparameter -list event.raw* {event.raw.00 100 1 100 0.99 channels} {event.raw.01 100 1 100 0.99 channels} {event.raw.02 100 1 100 0.99 channels} {event.raw.03 100 1 100 0.99 channels} {event.raw.04 100 1 100 0.99 channels} {event.raw.05 100 1 100 0.99 channels} {event.raw.06 100 1 100 0.99 channels} {event.raw.07 100 1 100 0.99 channels} {event.raw.08 100 1 100 0.99 channels} {event.raw.09 100 1 100 0.99 channels}
This subcommand sets the properties of a parameter to the indicated values. Each parameter has the following properties:
This subcommand sets the new channel width of the tree parametr named to inc. This is done by holding the values of bins and low constant and adjusting the value of high to achieve the desired width
This subcommand sets the new default channel count of the tree parameter named to bins. The low and high values are not modified, so this implies a change in the channel width.
This subcommand sets the unit label that is used by this parameter. The parameter units are used to label parameter's axes on spectra that involve this parameter when the spectrum is viewed in mapped mode.
This subcommand sets the default parameter axis limits for spectra created by the GUI. The number of bins is kept constant. This command, therefore, implies a change in the channel width.
Returns 0 if the parameter's modified flag is not set and 1 if it is. Each treeparameter has a modified flag associated with it. Whenever a parameter's properties are modified, this flag is set. The modified flag is never set as a result of programmatic assignments to the tree parameter value on event by event processing, only by modifying the properties of the parameter. The modified flag is used to determine if a parameter's properties must be seaved to file for later recovery.
(treeparam) 4 % treeparameter -check event.sum 0 (treeparam) 5 % treeparameter -setunit event.sum MeV (treeparam) 6 % treeparameter -check event.sum 1
Clears the parameter's modified flag.
(treeparam) 6 % treeparameter -check event.sum 1 (treeparam) 7 % treeparameter -uncheck event.sum (treeparam) 8 % treeparameter -check event.sum 0
Returns the version of the tree paramter system. Can be used to determine if the tree paramter software supports the functionality your script required. The version is returned in the form major.minor
SpecTcl Home General Information User Guide Programmer's Guide Obtaining and Installing