Skip to content

Scan Methods

Louis VASLIN edited this page Apr 9, 2021 · 6 revisions

Currently, there are two scan methods available:

  • One to perform a simple bump hunt (either excess and deficit)
  • One to perform a signal injection test (only in 1D for now)

Common features

The is_hist argument

All the scan methods can take distributions (bkg, data and sig) as input.

Those distributions can be either row unbinned distributions, or binned histograms.

If the distributions are unbinned, you can specify it with the is_hist argument (is_hist=False).
In this case, the distributions will be turned into binned histograms before performing the scan.

If the distributions are already in histogram form, you must specify it (is_hist=True).

If the is_hist argument is not specified, all scan methods will by default assume that the distributions are not in histogram form.

bump_scan

Method that perform a bump hunt on a 1D or 2D data distribution and compare it to a "expected" background distribution.

The bump_scan method will generate many pseudo-experiment by sampling from the background and produce a local p-value distribution from which is built the BumpHunter statistics distribution.

The global p-value is then calculated from this BumpHunter statistics distribution.

Arguments

The bump_scan method takes two distributions as input:

  • data
    The data on which the scan is performed

  • bkg
    The "expected" background used as a reference to be compared with data.

  • do_pseudo
    Boolean specifying if pseudo-data should be generated.
    If False, then the BumpHunter statistics distribution kept in memory is used to compute the global p-value and significance.
    If there is nothing in memory, the global p-value and significance will not be computed.
    This can be used to save time when doing several scans with the same reference background.
    Default to 'True'.

Results

The results produced by the bump_scan method are stored in the following inner result variables (common to BumpHunter1D and BumpHunter2D) :

  • .global_Pval

  • .significance

  • .res_ar

  • .min_Pval_ar

  • .min_loc_ar

  • .min_width_ar

  • .signal_eval

See the Inner result variables section for a detailed description.

signal_inject

Method that perform a signal injection test in order to evaluate the sensitivity of the bump hunt to a given signal considering a given background.

The signal_inject method generate pseudo-experiment by sampling only from the background in order to produce a BumpHunter statistics distribution like in the bump_scan function.

Then, the function generate pseudo-experiment using both background and signal in order to generate toys with a given signal strength.
These distributions are scanned in order to produce a BumpHunter statistics distributions which is compared to the background only distribution to compute a global p-value and significance.

The process is repeated with a growing signal strength until the required number of sigmas is reached.

NOTE : This method is not implemented in BumpHunter2D class yet.

Arguments

The signal_inject function takes two distributions as input:

  • sig
    The signal to be injected over the background
  • bkg
    The "expected" background used as a reference to be compared with data.

Results

In addition of the inner result variables used by the bump_scan method, the signal_inject method store its results in the following inner variables:

  • .signal_ratio

  • .signal_min

  • .data_inject

  • .sigma_ar

See the inner result variables section for a detailed description.

The inner result variables signal_inject share with the bump_scan method are filled with the results obtained during the last injection iteration (when the required sigma limit is reached).