CMS 3D CMS Logo

Public Member Functions | Public Attributes | Private Attributes

CommissioningTask::HistoSet Class Reference

#include <CommissioningTask.h>

List of all members.

Public Member Functions

uint32_t bin (float value)
void histo (MonitorElement *)
MonitorElementhisto ()
 HistoSet ()

Public Attributes

bool explicitFill_
bool isProfile_
std::vector< float > vNumOfEntries_
std::vector< float > vSumOfContents_
std::vector< double > vSumOfSquares_

Private Attributes

TAxis * axis_
MonitorElementhisto_

Detailed Description

Simple container class holding pointer to root histogram, and vectors in which data are cached and used to update histo.

Definition at line 37 of file CommissioningTask.h.


Constructor & Destructor Documentation

CommissioningTask::HistoSet::HistoSet ( )

Definition at line 86 of file CommissioningTask.cc.


Member Function Documentation

uint32_t CommissioningTask::HistoSet::bin ( float  value)

Definition at line 130 of file CommissioningTask.cc.

References axis_, and newFWLiteAna::bin.

Referenced by CommissioningTask::updateHistoSet().

                                                     {
  if ( !axis_ ) { return 0; }
  float range = axis_->GetXmax() - axis_->GetXmin();
  if ( range > 0. ) {
    int32_t bin = static_cast<int32_t>( ( value - axis_->GetXmin() ) * 
                                        ( axis_->GetNbins() / range ) ) + 1;
    if ( bin < 0 ) { return 0; }
    else if ( bin > axis_->GetNbins() ) { return static_cast<uint32_t>( axis_->GetNbins() + 1 ); }
    else { return bin; }
  } else { return 0; }      
}
void CommissioningTask::HistoSet::histo ( MonitorElement me)
MonitorElement * CommissioningTask::HistoSet::histo ( )

Definition at line 106 of file CommissioningTask.cc.

{ return histo_; }

Member Data Documentation

Definition at line 50 of file CommissioningTask.h.

Definition at line 49 of file CommissioningTask.h.