CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
utils.KS Class Reference
Inheritance diagram for utils.KS:
utils.StatisticalTest

Public Member Functions

def __init__ (self, threshold)
 
def do_test (self)
 
- Public Member Functions inherited from utils.StatisticalTest
def __init__ (self, threshold)
 
def do_test (self)
 
def get_rank (self)
 
def get_status (self)
 
def set_operands (self, h1, h2)
 

Public Attributes

 name
 
- Public Attributes inherited from utils.StatisticalTest
 h1
 
 h2
 
 is_init
 
 name
 
 rank
 2D! return test_codes["2D"] More...
 
 threshold
 

Detailed Description

Definition at line 190 of file utils.py.

Constructor & Destructor Documentation

def utils.KS.__init__ (   self,
  threshold 
)

Definition at line 191 of file utils.py.

191  def __init__(self, threshold):
192  StatisticalTest.__init__(self,threshold)
193  self.name="KS"
194 
def __init__(self, threshold)
Definition: utils.py:191

Member Function Documentation

def utils.KS.do_test (   self)

Definition at line 195 of file utils.py.

References FitSlicesYTool.h1, ConfigurableHisto.h1, DQMSourceExample.h1, utils.StatisticalTest.h1, PlotAlignmentValidation::DMRPlotInfo.h1, FitSlicesYTool.h2, EgammaTowerIsolationNew< NC >::Sum.h2, ConfigurableHisto.h2, EgammaTowerIsolationNew< NC >.h2, DQMSourceExample.h2, utils.StatisticalTest.h2, and PlotAlignmentValidation::DMRPlotInfo.h2.

195  def do_test(self):
196 
197  # Calculate errors if not there...
198  for h in self.h1,self.h2:
199  w2s=h.GetSumw2()
200  if w2s.GetSize()==0:
201  h.Sumw2()
202 
203  ## If errors are 0:
204  #zero_errors=True
205  #for h in self.h1,self.h2:
206  #for ibin in xrange(Nbins1):
207  #if h.GetBinError(ibin+1) >0:
208  #zero_errors=False
209  #break
210  #if zero_errors:
211  #return test_codes["ZERO_ERR"]
212 
213  return self.h1.KolmogorovTest(self.h2)
214 
215 #-------------------------------------------------------------------------------
def do_test(self)
Definition: utils.py:195

Member Data Documentation

utils.KS.name