For the preshower we are currently calculating relative calibration

We will assume that the gain in the 20 "rings" of constant eta along the barrel are an average that will eliminate the relative gain between the preshowers. By fitting a slope to the preshower ADC for all the towers in an eta rings, we can then calculate the gain, preshower by preshower, relative to this

The first correction that needed to be applied was the pedestal correction to the preshowers. The preshower have a "cut" in the Gaussian part of the peak that made it difficult to estimate the correct width of the RMS cut needed

The mean an rms from the pedestal runs were used to fit to the preshower ADC values and estimate the cut. The pedestal run data were fitted to the preshower adc data for 2, 2.5, 3, 3.5 RMS

By 'eye' a cut of 3 sigma would seem to be good, but after cutting and trying to fit and exponential to a number of towers, it was realised that the discrete nature of the ADC values often lead to a leading bins not being removed that were a bad fit. The best fit was to remove this bin with a 3.5 sigma cut on the preshower data

On average 2 to 3 bins are removed, which after a visual inspection on seemed OK

With the pedestal cut the preshower adc values were fitted with an exponential preshower by preshower. We used this point to check for any problems and remove dead preshowers.

Chi/ndf vs. preshower gives a good first indication of problem preshowers

Magnified

Another check was from the quality of the Least Log fit vs the ordinary bin by bin fit

Some of the worst offenders were removed by checking the status bit from the pedestal runs, anything other than 1 is cut. Some offenders are dead but seem to have a pedestal, some look OK but fall out of the pedestal cut. These "bad" preshowers seem to be picked up by cuts on the above, and the ideal selection is under investigation, but another good indicator seems to be the Least Log fit which for good preshowers is around:

exp^(a+xb)==> a=5.5 b=-0.15

Good tower but 2.5 sigma RMS leaving Gaussian

Low stats and noise Not removed by status bit.

Low stats and noise. Not removed by status bit.

For constant eta the towers in a "ring" around the barrel were selected, they were selected by modifying the code used to select the single tower ADC. In this case the pedestal is subtracted for each tower and they are summed together. Currently the only cut applied is a "Bad Status" from the pedestal runs. Finally the exponential is fitted to the ring

Range: 0.95-eta-1

Note: The fitting parameters need to be tuned in this preliminary example