Line | |
---|
1 | SELECT
|
---|
2 | -- Convert variable to bin index
|
---|
3 | INTERVAL(Theta, %107:theta) AS `.theta`,
|
---|
4 | INTERVAL(LogEnergyEst, %108:sparse) AS `.sparse_est`,
|
---|
5 |
|
---|
6 | -- Signal and Background counts
|
---|
7 | COUNT(IF(Weight>0, 1, NULL)) AS `Signal`,
|
---|
8 | COUNT(IF(Weight<0, 1, NULL)) AS `Background`,
|
---|
9 |
|
---|
10 | -- Average Energy: SumEnergyEst/SumW
|
---|
11 | SUM(Weight*POW(10, LogEnergyEst)) AS SumEnergyEst,
|
---|
12 | SUM(Weight) AS SumW
|
---|
13 | FROM
|
---|
14 | Excess
|
---|
15 | GROUP BY
|
---|
16 | `.theta`, `.sparse_est`
|
---|
17 | ORDER BY
|
---|
18 | `.theta`, `.sparse_est`
|
---|
Note:
See
TracBrowser
for help on using the repository browser.