CMS 3D CMS Logo

Functions

/data/refman/pasoursint/CMSSW_5_2_7_hltpatch1/src/CommonTools/Statistics/src/Accumulator.cc File Reference

#include "CommonTools/Statistics/interface/Accumulator.h"
#include <ostream>

Go to the source code of this file.

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;
}