CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
CaloValidationStatistics Class Reference

#include <CaloValidationStatistics.h>

Public Member Functions

void addEntry (float value, float weight=1.)
 
 CaloValidationStatistics (std::string name, float expectedMean, float expectedRMS)
 
float expectedMean () const
 
float expectedRMS () const
 
float mean () const
 
std::string name () const
 
int nEntries () const
 
float RMS () const
 
float weightedMean () const
 
 ~CaloValidationStatistics ()
 prints to LogInfo upon destruction More...
 

Private Attributes

float expectedMean_
 
float expectedRMS_
 
int n_
 
std::string name_
 
float sum_
 
float sumOfSquares_
 
float sumOfWeights_
 
float weightedSum_
 

Detailed Description

For validation purposes. This program calculates mean and RMS of a distribution

Rick Wilkinson

Definition at line 12 of file CaloValidationStatistics.h.

Constructor & Destructor Documentation

CaloValidationStatistics::CaloValidationStatistics ( std::string  name,
float  expectedMean,
float  expectedRMS 
)
CaloValidationStatistics::~CaloValidationStatistics ( )

prints to LogInfo upon destruction

Definition at line 16 of file CaloValidationStatistics.cc.

16 { edm::LogInfo("CaloValidationStatistics") << *this; }

Member Function Documentation

void CaloValidationStatistics::addEntry ( float  value,
float  weight = 1. 
)
float CaloValidationStatistics::expectedMean ( ) const
inline

Definition at line 28 of file CaloValidationStatistics.h.

References expectedMean_.

Referenced by operator<<().

float CaloValidationStatistics::expectedRMS ( ) const
inline

Definition at line 30 of file CaloValidationStatistics.h.

References expectedRMS_.

Referenced by operator<<().

float CaloValidationStatistics::mean ( ) const

Definition at line 26 of file CaloValidationStatistics.cc.

References n_, and sum_.

Referenced by name(), and operator<<().

std::string CaloValidationStatistics::name ( void  ) const
inline

Definition at line 20 of file CaloValidationStatistics.h.

References mean(), name_, RMS(), and weightedMean().

Referenced by config.CFG::__str__(), validation.Sample::digest(), and operator<<().

20 { return name_; }
int CaloValidationStatistics::nEntries ( ) const
inline

Definition at line 32 of file CaloValidationStatistics.h.

References n_.

Referenced by operator<<().

float CaloValidationStatistics::RMS ( ) const
float CaloValidationStatistics::weightedMean ( ) const

Definition at line 34 of file CaloValidationStatistics.cc.

References sumOfWeights_, and weightedSum_.

Referenced by name().

Member Data Documentation

float CaloValidationStatistics::expectedMean_
private

Definition at line 36 of file CaloValidationStatistics.h.

Referenced by expectedMean().

float CaloValidationStatistics::expectedRMS_
private

Definition at line 37 of file CaloValidationStatistics.h.

Referenced by expectedRMS().

int CaloValidationStatistics::n_
private

Definition at line 42 of file CaloValidationStatistics.h.

Referenced by addEntry(), mean(), nEntries(), and RMS().

std::string CaloValidationStatistics::name_
private

Definition at line 35 of file CaloValidationStatistics.h.

Referenced by name().

float CaloValidationStatistics::sum_
private

Definition at line 38 of file CaloValidationStatistics.h.

Referenced by addEntry(), mean(), and RMS().

float CaloValidationStatistics::sumOfSquares_
private

Definition at line 39 of file CaloValidationStatistics.h.

Referenced by addEntry(), and RMS().

float CaloValidationStatistics::sumOfWeights_
private

Definition at line 41 of file CaloValidationStatistics.h.

Referenced by addEntry(), and weightedMean().

float CaloValidationStatistics::weightedSum_
private

Definition at line 40 of file CaloValidationStatistics.h.

Referenced by addEntry(), and weightedMean().