11 const unsigned long binsX ,
14 const unsigned long binsY )
const
17 if ( !produceHistos() ) {
return 0 ; }
20 AIDA::IHistogram2D* hist = histo2D ( title ) ;
22 if( NULL != hist ) {
return hist ; }
26 newHistoID( title, ID );
29 return this -> book2D ( ID, title, lowX, highX, binsX, lowY, highY, binsY );
34 template <
class PBASE>
40 const unsigned long binsX ,
43 const unsigned long binsY )
const
46 if ( !produceHistos() ) {
return 0 ; }
51 this->Error(
"Undefined Histogram ID : Title='"+title+
"'");
56 AIDA::IHistogram2D* hist = histo2D( ID ) ;
58 if( NULL != hist ) {
return hist ; }
62 ( title.empty() ?
"Unnamed 2D Histogram ID="+ID.
idAsString() : title ) ;
67 hist = this->histoSvc() ->
book ( histoPath() ,
79 hist = this->histoSvc() ->
book ( histoPath()+
"/"+
92 { this->Error(
"IHistogram2D* points to NULL! ID='" + ID.
idAsString() +
93 "' title='"+htitle+
"'" ) ;
return NULL; }
96 m_histo2DMapID [ ID ] = hist ;
97 m_histo2DMapTitle [ title ] = hist ;
104 { this->debug() <<
"Booked 2D Histogram : ID='"
105 << ID <<
"' Path=" << histoPath()
115 template <
class PBASE>
117 ( AIDA::IHistogram2D* histo ,
118 const double valueX ,
119 const double valueY ,
120 const double weight ,
124 if ( NULL == histo ) {
return 0 ; }
126 if ( !checkForNaN() )
128 else if ( lfin ( valueX ) && lfin ( valueY ) && lfin ( weight ) )
130 else if ( lnan ( valueX ) || lnan ( valueY ) || lnan ( weight ) )
133 (
"fill():: 'NaN' value is skipped from the histogram '"
139 (
"fill():: 'Infinite' value is skipped from the histogram '"
148 template <
class PBASE>
150 (
const double valueX ,
151 const double valueY ,
157 const unsigned long binsX ,
158 const unsigned long binsY ,
159 const double weight )
const
161 AIDA::IHistogram2D * h(NULL);
162 if ( produceHistos() )
165 h = histo2D ( title ) ;
167 { h = book2D ( title , lowX , highX , binsX , lowY , highY , binsY ) ; }
169 h =
fill ( h , valueX , valueY , weight , title ) ;
176 template <
class PBASE>
178 (
const double valueX ,
179 const double valueY ,
186 const unsigned long binsX ,
187 const unsigned long binsY ,
188 const double weight )
const
190 AIDA::IHistogram2D * h(NULL);
192 if ( produceHistos() )
196 if ( NULL == h ) { h = book2D ( ID , title ,
197 lowX , highX , binsX ,
198 lowY , highY , binsY ) ; }
200 h =
fill ( h , valueX , valueY , weight , title ) ;