CMS 3D CMS Logo

Classes | Functions

/data/doxygen/doxygen-1.7.3/gen/CMSSW_4_2_8/src/CommonTools/Statistics/interface/Accumulator.h File Reference

#include <iosfwd>
#include <cmath>

Go to the source code of this file.

Classes

class  Accumulator

Functions

std::ostream & operator<< (std::ostream &os, const Accumulator &stat)

Function Documentation

std::ostream& operator<< ( std::ostream &  os,
const Accumulator stat 
)

Definition at line 40 of file Accumulator.cc.

References Accumulator::mean(), Accumulator::nEntries(), and Accumulator::sigma().

                                                                 {
  os << "entries: " << stat.nEntries();
  if(stat.nEntries() > 0) {
     os << "   Mean: " << stat.mean(); 
  }
  if(stat.nEntries() > 1) {      
                 os << "   Sigma: " << stat.sigma();
  }
  return os;
}