docstr: Berk-Jones score function is a non parametric expectatation based
  scan statistic that also satisfies the ALTSS property; Non-parametric scoring functions
  do not make parametric assumptions about the model or outcome [1].
  
  kwargs must contain
  'direction (str)' - direction of the severity; could be higher than expected outcomes ('positive') or lower than expected ('negative')
  'alpha (float)' - the alpha threshold that will be used to compute the score.
      In practice, it may be useful to search over a grid of alpha thresholds and select the one with the maximum score.
  
  
  [1] Neill, D. B., & Lingwall, J. (2007). A nonparametric scan statistic for multivariate disease surveillance. Advances in
  Disease Surveillance, 4(106), 570
code: def __init__(self, **kwargs):
      """
      Berk-Jones score function is a non parametric expectatation based
      scan statistic that also satisfies the ALTSS property; Non-parametric scoring functions
      do not make parametric assumptions about the model or outcome [1].
  
      kwargs must contain
      'direction (str)' - direction of the severity; could be higher than expected outcomes ('positive') or lower than expected ('negative')
      'alpha (float)' - the alpha threshold that will be used to compute the score.
          In practice, it may be useful to search over a grid of alpha thresholds and select the one with the maximum score.
  
  
      [1] Neill, D. B., & Lingwall, J. (2007). A nonparametric scan statistic for multivariate disease surveillance. Advances in
      Disease Surveillance, 4(106), 570
      """
  
      super(BerkJones, self).__init__(**kwargs)
      self.alpha = self.kwargs.get("alpha")
      assert (
          self.alpha is not None
      ), "Warning: calling Berk Jones without alpha"
  
      if self.direction == "negative":
          self.alpha = 1 - self.alpha
  
file_path: AIF360/aif360/detectors/mdss/ScoringFunctions/BerkJones.py
imports: from aif360.detectors.mdss.ScoringFunctions.ScoringFunction import ScoringFunction
  from aif360.detectors.mdss.ScoringFunctions import optim
  import numpy
label_desc: Use image node_id 1 to create a new BerkJones object from inherited base classes: ScoringFunction with example: obj = BerkJones()