All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Public Attributes | List of all members
ICARUSgeometryChecker.StatCollector Class Reference

Public Member Functions

def __init__
 
def reset
 
def add
 
def entries
 
def weightSum
 
def sum
 
def sumSq
 
def average
 
def averageSq
 
def variance
 
def RMS
 

Public Attributes

 n
 
 w
 
 wx
 
 wx2
 

Detailed Description

Definition at line 620 of file ICARUSgeometryChecker.py.

Constructor & Destructor Documentation

def ICARUSgeometryChecker.StatCollector.__init__ (   self)

Member Function Documentation

def ICARUSgeometryChecker.StatCollector.add (   self,
  value,
  weight = 1.0 
)

Definition at line 628 of file ICARUSgeometryChecker.py.

629  def add(self, value, weight = 1.0):
630  self.n += 1
631  self.w += weight
632  self.wx += weight * value
self.wx2 += weight * value**2
def ICARUSgeometryChecker.StatCollector.average (   self)

Definition at line 638 of file ICARUSgeometryChecker.py.

def average(self): return self.wx / self.w if self.w else None
def ICARUSgeometryChecker.StatCollector.averageSq (   self)

Definition at line 639 of file ICARUSgeometryChecker.py.

def averageSq(self): return self.wx2 / self.w if self.w else None
def ICARUSgeometryChecker.StatCollector.entries (   self)

Definition at line 634 of file ICARUSgeometryChecker.py.

def entries(self): return self.n
def ICARUSgeometryChecker.StatCollector.reset (   self)

Definition at line 622 of file ICARUSgeometryChecker.py.

623  def reset(self):
624  self.n = 0
625  self.w = 0.0
626  self.wx = 0.0
self.wx2 = 0.0
def ICARUSgeometryChecker.StatCollector.RMS (   self)

Definition at line 642 of file ICARUSgeometryChecker.py.

643  def RMS(self): return self.variance() ** 0.5 if self.w else None
644 # class StatCollector
645 
646 
# ##############################################################################
def ICARUSgeometryChecker.StatCollector.sum (   self)

Definition at line 636 of file ICARUSgeometryChecker.py.

def sum(self): return self.wx
def ICARUSgeometryChecker.StatCollector.sumSq (   self)

Definition at line 637 of file ICARUSgeometryChecker.py.

def sumSq(self): return self.wx2
def ICARUSgeometryChecker.StatCollector.variance (   self)

Definition at line 640 of file ICARUSgeometryChecker.py.

641  def variance(self):
return self.averageSq() - self.average()**2 if self.w else None
def ICARUSgeometryChecker.StatCollector.weightSum (   self)

Definition at line 635 of file ICARUSgeometryChecker.py.

def weightSum(self): return self.w

Member Data Documentation

ICARUSgeometryChecker.StatCollector.n

Definition at line 623 of file ICARUSgeometryChecker.py.

ICARUSgeometryChecker.StatCollector.w

Definition at line 624 of file ICARUSgeometryChecker.py.

ICARUSgeometryChecker.StatCollector.wx

Definition at line 625 of file ICARUSgeometryChecker.py.

ICARUSgeometryChecker.StatCollector.wx2

Definition at line 626 of file ICARUSgeometryChecker.py.


The documentation for this class was generated from the following file: