; DESCRIPTION: ; Defines histograms for TUNL nday star experiment ; ; ; BOOK H-BOOK HISTOGRAMS ; begin hist unconditional ; HITREG, hitreg, 64, 0., 64. $Hit Register UCDET1TOF,det_tof(1),1024,0.,4096. $Det1 tof UCDET2TOF,det_tof(2),1024,0.,4096. $Det2 tof UCDET3TOF,det_tof(1),det_tof(2),1024,0.,4096.,1024,0.,4096. $Det2 tof ; end hist unconditional ; ; begin hist conditional ; DET1SPH,det_phshort(1),1024,0.,4096.,testid(1) $Det1 short pulse height DET2SPH,det_phshort(2),1024,0.,4096.,testid(2) $Det2 short pulse height ; end hist conditional
This file is divided into two sections, an unconditonal block and a conditional one. The histograms defined in the unconditonal block will NOT be gated by any cuts. The histograms defined in the conditonal block will be gated by tests defined in the test file, as described later. Each 1-d histogram line has the following structure.
unconditional
NAME, VARIABLE, # of Bins, Min, Max $LABEL
conditional
NAME, VARIABLE, # of Bins, Min, Max, CUT $LABEL
The NAME is a local parameter and must be unique to a histogram. The VARIABLE is the name of the quantity which needs to be plotted. All raw data quantities are available in the array rawdet(). In addition, any other variables can be defined in the usr_inc.h file (along with the common block) and used in this hist file. The bins are channels between the Minimum (Min) and Maximum (Max) limits of the histograms. For the case of the conditional histograms, the next field, CUT, is the test quantity. The test variables are decleared in a long array called testid(). The histogram VARIABLE will be gated by the cut defined as testid(#). The title which will appear with the histogram is defined as $LABEL.
The 2-d histograms take a similar form :
NAME, VAR 1, VAR 2, Chn1, Min1, Max1, Chn2, Min2, Max2 $LABEL The histogram package is an interpreted code. The analyzer does not need to be compiled if a change is made in the histograms file. However, the analyzer needs to be restarted for the changes to take place.