ROOT logo
/*****************************************************************************
 * Project: RooFit                                                           *
 * Package: RooFitCore                                                       *
 * @(#)root/roofitcore:$Id: RooAbsTestStatistic.cxx 28259 2009-04-16 16:21:16Z wouter $
 * Authors:                                                                  *
 *   WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu       *
 *   DK, David Kirkby,    UC Irvine,         dkirkby@uci.edu                 *
 *                                                                           *
 * Copyright (c) 2000-2005, Regents of the University of California          *
 *                          and Stanford University. All rights reserved.    *
 *                                                                           *
 * Redistribution and use in source and binary forms,                        *
 * with or without modification, are permitted according to the terms        *
 * listed in LICENSE (http://roofit.sourceforge.net/license.txt)             *
 *****************************************************************************/

//////////////////////////////////////////////////////////////////////////////
// 
// BEGIN_HTML
// RooAbsTestStatistic is the abstract base class for all test
// statistics. Test statistics that evaluate the PDF at each data
// point should inherit from the RooAbsOptTestStatistic class which
// implements several generic optimizations that can be done for such
// quantities.
//
// This test statistic base class organizes calculation of test
// statistic values for RooSimultaneous PDF as a combination of test
// statistic values for the PDF components of the simultaneous PDF and
// organizes multi-processor parallel calculation of test statistic
// values. For the latter, the test statistic value is calculated in
// partitions in parallel executing processes and a posteriori
// combined in the main thread.
// END_HTML
//


#include "RooFit.h"
#include "Riostream.h"

#include "RooAbsTestStatistic.h"
#include "RooAbsPdf.h"
#include "RooSimultaneous.h"
#include "RooAbsData.h"
#include "RooArgSet.h"
#include "RooRealVar.h"
#include "RooNLLVar.h"
#include "RooRealMPFE.h"
#include "RooErrorHandler.h"
#include "RooMsgService.h"

ClassImp(RooAbsTestStatistic)
;


//_____________________________________________________________________________
RooAbsTestStatistic::RooAbsTestStatistic() 
{ 
  // Default constructor

  _init = kFALSE ; 
  _gofArray = 0 ;
  _mpfeArray = 0 ;
}



//_____________________________________________________________________________
RooAbsTestStatistic::RooAbsTestStatistic(const char *name, const char *title, RooAbsReal& real, RooAbsData& data,
					 const RooArgSet& projDeps, const char* rangeName, const char* addCoefRangeName, 
					 Int_t nCPU, Bool_t interleave, Bool_t verbose, Bool_t splitCutRange) : 
  RooAbsReal(name,title),
  _paramSet("paramSet","Set of parameters",this),
  _func(&real),
  _data(&data),
  _projDeps((RooArgSet*)projDeps.Clone()),
  _rangeName(rangeName?rangeName:""),
  _addCoefRangeName(addCoefRangeName?addCoefRangeName:""),
  _splitRange(splitCutRange),
  _simCount(1),
  _verbose(verbose),
  _nGof(0),
  _gofArray(0),
  _nCPU(nCPU),
  _mpfeArray(0),
  _mpinterl(interleave)
{
  // Constructor taking function (real), a dataset (data), a set of projected observables (projSet). If 
  // rangeName is not null, only events in the dataset inside the range will be used in the test
  // statistic calculation. If addCoefRangeName is not null, all RooAddPdf component of 'real' will be
  // instructed to fix their fraction definitions to the given named range. If nCPU is greater than
  // 1 the test statistic calculation will be paralellized over multiple processes. By default the data
  // is split with 'bulk' partitioning (each process calculates a contigious block of fraction 1/nCPU
  // of the data). For binned data this approach may be suboptimal as the number of bins with >0 entries
  // in each processing block many vary greatly thereby distributing the workload rather unevenly.
  // If interleave is set to true, the interleave partitioning strategy is used where each partition
  // i takes all bins for which (ibin % ncpu == i) which is more likely to result in an even workload.
  // If splitCutRange is true, a different rangeName constructed as rangeName_{catName} will be used
  // as range definition for each index state of a RooSimultaneous


  // Register all parameters as servers 
  RooArgSet* params = real.getParameters(&data) ;
  _paramSet.add(*params) ;
  delete params ;

  if (_nCPU>1) {

    _gofOpMode = MPMaster ;

  } else {

    // Determine if RooAbsReal is a RooSimultaneous
    Bool_t simMode = dynamic_cast<RooSimultaneous*>(&real)?kTRUE:kFALSE ;
    
    if (simMode) {
      _gofOpMode = SimMaster ;
    } else {
      _gofOpMode = Slave ;
    }
  }

  _setNum = 0 ;
  _numSets = 1 ;
  _init = kFALSE ;
  _nEvents = data.numEntries() ;
}



//_____________________________________________________________________________
RooAbsTestStatistic::RooAbsTestStatistic(const RooAbsTestStatistic& other, const char* name) : 
  RooAbsReal(other,name), 
  _paramSet("paramSet","Set of parameters",this),
  _func(other._func),
  _data(other._data),
  _projDeps((RooArgSet*)other._projDeps->Clone()),
  _rangeName(other._rangeName),
  _addCoefRangeName(other._addCoefRangeName),
  _splitRange(other._splitRange),
  _simCount(1),
  _verbose(other._verbose),
  _nGof(0),
  _gofArray(0),
  _nCPU(other._nCPU),
  _mpfeArray(0),
  _mpinterl(other._mpinterl)
{
  // Copy constructor

  // Our parameters are those of original
  _paramSet.add(other._paramSet) ;

  if (_nCPU>1) {

    _gofOpMode = MPMaster ;

  } else {

    // Determine if RooAbsReal is a RooSimultaneous
    Bool_t simMode = dynamic_cast<RooSimultaneous*>(_func)?kTRUE:kFALSE ;
    
    if (simMode) {
      _gofOpMode = SimMaster ;
    } else {
      _gofOpMode = Slave ;
    }
  }

  _setNum = 0 ;
  _numSets = 1 ;
  _init = kFALSE ;
  _nEvents = _data->numEntries() ;

  
}



//_____________________________________________________________________________
RooAbsTestStatistic::~RooAbsTestStatistic()
{
  // Destructor

  if (_gofOpMode==MPMaster && _init) {
    Int_t i ;
    for (i=0 ; i<_nCPU ; i++) {
      delete _mpfeArray[i] ;
    }
    delete[] _mpfeArray ;
  }

  if (_gofOpMode==SimMaster && _init) {
    Int_t i ;
    for (i=0 ; i<_nGof ; i++) {
      delete _gofArray[i] ;      
    }
    delete[] _gofArray ;
  }

  delete _projDeps ;
}



//_____________________________________________________________________________
Double_t RooAbsTestStatistic::evaluate() const
{
  // Calculates and return value of test statistic. If the test statistic
  // is calculated from on a RooSimultaneous, the test statistic calculation
  // is performed separately on each simultaneous p.d.f component and associated
  // data and then combined. If the test statistic calculation is parallelized
  // partitions are calculated in nCPU processes and a posteriori combined.

  // One-time Initialization
  if (!_init) {
    const_cast<RooAbsTestStatistic*>(this)->initialize() ;
  }

  if (_gofOpMode==SimMaster) {

    // Evaluate array of owned GOF objects
    Double_t ret = combinedValue((RooAbsReal**)_gofArray,_nGof) ;

    // Only apply global normalization if SimMaster doesn't have MP master
    if (numSets()==1) {
      ret /= globalNormalization() ;
    }

    return ret ;

  } else if (_gofOpMode==MPMaster) {

    // Start calculations in parallel 
    Int_t i ;
    for (i=0 ; i<_nCPU ; i++) {
      _mpfeArray[i]->calculate() ;
    }
    Double_t ret = combinedValue((RooAbsReal**)_mpfeArray,_nCPU)/globalNormalization() ;
    return ret ;

  } else {

    // Evaluate as straight FUNC
    Int_t nFirst, nLast, nStep ;
    if (_mpinterl) {
      nFirst = _setNum ;
      nLast  = _nEvents ;
      nStep  = _numSets ;
    } else {
      nFirst = _nEvents * _setNum / _numSets ;
      nLast  = _nEvents * (_setNum+1) / _numSets ;    
      nStep  = 1 ;
    }


    //cout << "nCPU = " << _nCPU << (_mpinterl?"INTERLEAVE":"BULK") << " nFirst = " << nFirst << " nLast = " << nLast << " nStep = " << nStep << endl ;
    
    Double_t ret =  evaluatePartition(nFirst,nLast,nStep) ;
    if (numSets()==1) {
      ret /= globalNormalization() ;
    }

    return ret ;

  }
}



//_____________________________________________________________________________
Bool_t RooAbsTestStatistic::initialize() 
{
  // One-time initialization of the test statistic. Setup
  // infrastructure for simultaneous p.d.f processing and/or
  // parallelized processing if requested

  if (_init) return kFALSE ;

  if (_gofOpMode==MPMaster) {
    initMPMode(_func,_data,_projDeps,_rangeName.size()?_rangeName.c_str():0,_addCoefRangeName.size()?_addCoefRangeName.c_str():0) ;
  } else if (_gofOpMode==SimMaster) {
    initSimMode((RooSimultaneous*)_func,_data,_projDeps,_rangeName.size()?_rangeName.c_str():0,_addCoefRangeName.size()?_addCoefRangeName.c_str():0) ;
  }
  _init = kTRUE ;
  return kFALSE ;
}



//_____________________________________________________________________________
Bool_t RooAbsTestStatistic::redirectServersHook(const RooAbsCollection& newServerList, Bool_t mustReplaceAll, Bool_t nameChange, Bool_t) 
{
  // Forward server redirect calls to component test statistics

  if (_gofOpMode==SimMaster && _gofArray) {
    // Forward to slaves
    Int_t i ;
    for (i=0 ; i<_nGof ; i++) {
      if (_gofArray[i]) {
	_gofArray[i]->recursiveRedirectServers(newServerList,mustReplaceAll,nameChange) ;
      }
    }
  } else if (_gofOpMode==MPMaster && _mpfeArray) {

    // Forward to slaves
    Int_t i ;
    for (i=0 ; i<_nCPU ; i++) {
      if (_mpfeArray[i]) {
	_mpfeArray[i]->recursiveRedirectServers(newServerList,mustReplaceAll,nameChange) ;
	cout << "redirecting servers on " << _mpfeArray[i]->GetName() << endl ;
      }
    }    

  }
  return kFALSE ;
}



//_____________________________________________________________________________
void RooAbsTestStatistic::printCompactTreeHook(ostream& os, const char* indent) 
{
  // Add extra information on component test statistics when printing 
  // itself as part of a tree structure

  if (_gofOpMode==SimMaster) {
    // Forward to slaves
    Int_t i ;
    os << indent << "RooAbsTestStatistic begin GOF contents" << endl ;
    for (i=0 ; i<_nGof ; i++) {
      if (_gofArray[i]) {
	TString indent2(indent) ;
	indent2 += Form("[%d] ",i) ;
	_gofArray[i]->printCompactTreeHook(os,indent2) ;
      }
    }
    os << indent << "RooAbsTestStatistic end GOF contents" << endl ;
  } else if (_gofOpMode==MPMaster) {
    // WVE implement this
  }
}



//_____________________________________________________________________________
void RooAbsTestStatistic::constOptimizeTestStatistic(ConstOpCode opcode) 
{
  // Forward constant term optimization management calls to component
  // test statistics
  Int_t i ;
  initialize() ;
  if (_gofOpMode==SimMaster) {
    // Forward to slaves    
    for (i=0 ; i<_nGof ; i++) {
      if (_gofArray[i]) _gofArray[i]->constOptimizeTestStatistic(opcode) ;
    }
  } else if (_gofOpMode==MPMaster) {
    for (i=0 ; i<_nCPU ; i++) {
      _mpfeArray[i]->constOptimizeTestStatistic(opcode) ;
    }
  }
}



//_____________________________________________________________________________
void RooAbsTestStatistic::setMPSet(Int_t inSetNum, Int_t inNumSets) 
{
  // Set MultiProcessor set number identification of this instance

  _setNum = inSetNum ; _numSets = inNumSets ;
  if (_gofOpMode==SimMaster) {
    // Forward to slaves
    initialize() ;
    Int_t i ;
    for (i=0 ; i<_nGof ; i++) {
      if (_gofArray[i]) _gofArray[i]->setMPSet(inSetNum,inNumSets) ;
    }
  } 
}



//_____________________________________________________________________________
void RooAbsTestStatistic::initMPMode(RooAbsReal* real, RooAbsData* data, const RooArgSet* projDeps, const char* rangeName, const char* addCoefRangeName)
{
  // Initialize multi-processor calculation mode. Create component test statistics in separate
  // processed that are connected to this process through a RooAbsRealMPFE front-end class.

  Int_t i ;
  _mpfeArray = new pRooRealMPFE[_nCPU] ;

  // Create proto-goodness-of-fit 
  RooAbsTestStatistic* gof = create(GetName(),GetTitle(),*real,*data,*projDeps,rangeName,addCoefRangeName,1,_mpinterl,_verbose,_splitRange) ;
  gof->recursiveRedirectServers(_paramSet) ;

  for (i=0 ; i<_nCPU ; i++) {

    gof->setMPSet(i,_nCPU) ;
    gof->SetName(Form("%s_GOF%d",GetName(),i)) ;
    gof->SetTitle(Form("%s_GOF%d",GetTitle(),i)) ;
    
    Bool_t doInline = (i==_nCPU-1) ;
    if (!doInline) coutI(Eval) << "RooAbsTestStatistic::initMPMode: starting remote server process #" << i << endl ; 
    _mpfeArray[i] = new RooRealMPFE(Form("%s_%x_MPFE%d",GetName(),this,i),Form("%s_%x_MPFE%d",GetTitle(),this,i),*gof,doInline) ;    
    _mpfeArray[i]->initialize() ;
  }
  //cout << "initMPMode --- done" << endl ;
  return ;
}



//_____________________________________________________________________________
void RooAbsTestStatistic::initSimMode(RooSimultaneous* simpdf, RooAbsData* data, 
				      const RooArgSet* projDeps, const char* rangeName, const char* addCoefRangeName)
{
  // Initialize simultaneous p.d.f processing mode. Strip simultaneous
  // p.d.f into individual components, split dataset in subset
  // matching each component and create component test statistics for
  // each of them.


  RooAbsCategoryLValue& simCat = (RooAbsCategoryLValue&) simpdf->indexCat() ;


  TString simCatName(simCat.GetName()) ;
  TList* dsetList = const_cast<RooAbsData*>(data)->split(simCat) ;
  if (!dsetList) {
    coutE(Fitting) << "RooAbsTestStatistic::initSimMode(" << GetName() << ") unable to split dataset, abort" << endl ;
    RooErrorHandler::softAbort() ;
  }

  // Count number of used states
  Int_t n(0) ;
  _nGof = 0 ;
  RooCatType* type ;
  TIterator* catIter = simCat.typeIterator() ;
  while((type=(RooCatType*)catIter->Next())){

    // Retrieve the PDF for this simCat state
    RooAbsPdf* pdf =  simpdf->getPdf(type->GetName()) ;
    RooAbsData* dset = (RooAbsData*) dsetList->FindObject(type->GetName()) ;

    if (pdf && dset && (dset->sumEntries()!=0. || processEmptyDataSets() )) {      
      _nGof++ ;
    }
  }

  // Allocate arrays 
  _gofArray = new pRooAbsTestStatistic[_nGof] ;

  // Create array of regular fit contexts, containing subset of data and single fitCat PDF
  catIter->Reset() ;
  while((type=(RooCatType*)catIter->Next())){

    // Retrieve the PDF for this simCat state
    RooAbsPdf* pdf =  simpdf->getPdf(type->GetName()) ;
    RooAbsData* dset = (RooAbsData*) dsetList->FindObject(type->GetName()) ;

    if (pdf && dset && (dset->sumEntries()!=0. || processEmptyDataSets())) {      
      coutI(Fitting) << "RooAbsTestStatistic::initSimMode: creating slave calculator #" << n << " for state " << type->GetName() 
		     << " (" << dset->numEntries() << " dataset entries)" << endl ;

      if (_splitRange && rangeName) {
	_gofArray[n] = create(type->GetName(),type->GetName(),*pdf,*dset,*projDeps,
			      Form("%s_%s",rangeName,type->GetName()),addCoefRangeName,_nCPU*(_mpinterl?-1:1),_mpinterl,_verbose,_splitRange) ;
      } else {
	_gofArray[n] = create(type->GetName(),type->GetName(),*pdf,*dset,*projDeps,
			      rangeName,addCoefRangeName,_nCPU,_mpinterl,_verbose,_splitRange) ;
      }
      _gofArray[n]->setSimCount(_nGof) ;
      
      // Servers may have been redirected between instantiation and (deferred) initialization
      _gofArray[n]->recursiveRedirectServers(_paramSet) ;
      n++ ;
    } else {
      if ((!dset || (dset->sumEntries()==0. && !processEmptyDataSets()) ) && pdf) {
	if (_verbose) {
	  coutI(Fitting) << "RooAbsTestStatistic::initSimMode: state " << type->GetName() 
			 << " has no data entries, no slave calculator created" << endl ;
	}
      }      
    }
  }

  dsetList->Delete() ;
  delete dsetList ;
  delete catIter ;
}





 RooAbsTestStatistic.cxx:1
 RooAbsTestStatistic.cxx:2
 RooAbsTestStatistic.cxx:3
 RooAbsTestStatistic.cxx:4
 RooAbsTestStatistic.cxx:5
 RooAbsTestStatistic.cxx:6
 RooAbsTestStatistic.cxx:7
 RooAbsTestStatistic.cxx:8
 RooAbsTestStatistic.cxx:9
 RooAbsTestStatistic.cxx:10
 RooAbsTestStatistic.cxx:11
 RooAbsTestStatistic.cxx:12
 RooAbsTestStatistic.cxx:13
 RooAbsTestStatistic.cxx:14
 RooAbsTestStatistic.cxx:15
 RooAbsTestStatistic.cxx:16
 RooAbsTestStatistic.cxx:17
 RooAbsTestStatistic.cxx:18
 RooAbsTestStatistic.cxx:19
 RooAbsTestStatistic.cxx:20
 RooAbsTestStatistic.cxx:21
 RooAbsTestStatistic.cxx:22
 RooAbsTestStatistic.cxx:23
 RooAbsTestStatistic.cxx:24
 RooAbsTestStatistic.cxx:25
 RooAbsTestStatistic.cxx:26
 RooAbsTestStatistic.cxx:27
 RooAbsTestStatistic.cxx:28
 RooAbsTestStatistic.cxx:29
 RooAbsTestStatistic.cxx:30
 RooAbsTestStatistic.cxx:31
 RooAbsTestStatistic.cxx:32
 RooAbsTestStatistic.cxx:33
 RooAbsTestStatistic.cxx:34
 RooAbsTestStatistic.cxx:35
 RooAbsTestStatistic.cxx:36
 RooAbsTestStatistic.cxx:37
 RooAbsTestStatistic.cxx:38
 RooAbsTestStatistic.cxx:39
 RooAbsTestStatistic.cxx:40
 RooAbsTestStatistic.cxx:41
 RooAbsTestStatistic.cxx:42
 RooAbsTestStatistic.cxx:43
 RooAbsTestStatistic.cxx:44
 RooAbsTestStatistic.cxx:45
 RooAbsTestStatistic.cxx:46
 RooAbsTestStatistic.cxx:47
 RooAbsTestStatistic.cxx:48
 RooAbsTestStatistic.cxx:49
 RooAbsTestStatistic.cxx:50
 RooAbsTestStatistic.cxx:51
 RooAbsTestStatistic.cxx:52
 RooAbsTestStatistic.cxx:53
 RooAbsTestStatistic.cxx:54
 RooAbsTestStatistic.cxx:55
 RooAbsTestStatistic.cxx:56
 RooAbsTestStatistic.cxx:57
 RooAbsTestStatistic.cxx:58
 RooAbsTestStatistic.cxx:59
 RooAbsTestStatistic.cxx:60
 RooAbsTestStatistic.cxx:61
 RooAbsTestStatistic.cxx:62
 RooAbsTestStatistic.cxx:63
 RooAbsTestStatistic.cxx:64
 RooAbsTestStatistic.cxx:65
 RooAbsTestStatistic.cxx:66
 RooAbsTestStatistic.cxx:67
 RooAbsTestStatistic.cxx:68
 RooAbsTestStatistic.cxx:69
 RooAbsTestStatistic.cxx:70
 RooAbsTestStatistic.cxx:71
 RooAbsTestStatistic.cxx:72
 RooAbsTestStatistic.cxx:73
 RooAbsTestStatistic.cxx:74
 RooAbsTestStatistic.cxx:75
 RooAbsTestStatistic.cxx:76
 RooAbsTestStatistic.cxx:77
 RooAbsTestStatistic.cxx:78
 RooAbsTestStatistic.cxx:79
 RooAbsTestStatistic.cxx:80
 RooAbsTestStatistic.cxx:81
 RooAbsTestStatistic.cxx:82
 RooAbsTestStatistic.cxx:83
 RooAbsTestStatistic.cxx:84
 RooAbsTestStatistic.cxx:85
 RooAbsTestStatistic.cxx:86
 RooAbsTestStatistic.cxx:87
 RooAbsTestStatistic.cxx:88
 RooAbsTestStatistic.cxx:89
 RooAbsTestStatistic.cxx:90
 RooAbsTestStatistic.cxx:91
 RooAbsTestStatistic.cxx:92
 RooAbsTestStatistic.cxx:93
 RooAbsTestStatistic.cxx:94
 RooAbsTestStatistic.cxx:95
 RooAbsTestStatistic.cxx:96
 RooAbsTestStatistic.cxx:97
 RooAbsTestStatistic.cxx:98
 RooAbsTestStatistic.cxx:99
 RooAbsTestStatistic.cxx:100
 RooAbsTestStatistic.cxx:101
 RooAbsTestStatistic.cxx:102
 RooAbsTestStatistic.cxx:103
 RooAbsTestStatistic.cxx:104
 RooAbsTestStatistic.cxx:105
 RooAbsTestStatistic.cxx:106
 RooAbsTestStatistic.cxx:107
 RooAbsTestStatistic.cxx:108
 RooAbsTestStatistic.cxx:109
 RooAbsTestStatistic.cxx:110
 RooAbsTestStatistic.cxx:111
 RooAbsTestStatistic.cxx:112
 RooAbsTestStatistic.cxx:113
 RooAbsTestStatistic.cxx:114
 RooAbsTestStatistic.cxx:115
 RooAbsTestStatistic.cxx:116
 RooAbsTestStatistic.cxx:117
 RooAbsTestStatistic.cxx:118
 RooAbsTestStatistic.cxx:119
 RooAbsTestStatistic.cxx:120
 RooAbsTestStatistic.cxx:121
 RooAbsTestStatistic.cxx:122
 RooAbsTestStatistic.cxx:123
 RooAbsTestStatistic.cxx:124
 RooAbsTestStatistic.cxx:125
 RooAbsTestStatistic.cxx:126
 RooAbsTestStatistic.cxx:127
 RooAbsTestStatistic.cxx:128
 RooAbsTestStatistic.cxx:129
 RooAbsTestStatistic.cxx:130
 RooAbsTestStatistic.cxx:131
 RooAbsTestStatistic.cxx:132
 RooAbsTestStatistic.cxx:133
 RooAbsTestStatistic.cxx:134
 RooAbsTestStatistic.cxx:135
 RooAbsTestStatistic.cxx:136
 RooAbsTestStatistic.cxx:137
 RooAbsTestStatistic.cxx:138
 RooAbsTestStatistic.cxx:139
 RooAbsTestStatistic.cxx:140
 RooAbsTestStatistic.cxx:141
 RooAbsTestStatistic.cxx:142
 RooAbsTestStatistic.cxx:143
 RooAbsTestStatistic.cxx:144
 RooAbsTestStatistic.cxx:145
 RooAbsTestStatistic.cxx:146
 RooAbsTestStatistic.cxx:147
 RooAbsTestStatistic.cxx:148
 RooAbsTestStatistic.cxx:149
 RooAbsTestStatistic.cxx:150
 RooAbsTestStatistic.cxx:151
 RooAbsTestStatistic.cxx:152
 RooAbsTestStatistic.cxx:153
 RooAbsTestStatistic.cxx:154
 RooAbsTestStatistic.cxx:155
 RooAbsTestStatistic.cxx:156
 RooAbsTestStatistic.cxx:157
 RooAbsTestStatistic.cxx:158
 RooAbsTestStatistic.cxx:159
 RooAbsTestStatistic.cxx:160
 RooAbsTestStatistic.cxx:161
 RooAbsTestStatistic.cxx:162
 RooAbsTestStatistic.cxx:163
 RooAbsTestStatistic.cxx:164
 RooAbsTestStatistic.cxx:165
 RooAbsTestStatistic.cxx:166
 RooAbsTestStatistic.cxx:167
 RooAbsTestStatistic.cxx:168
 RooAbsTestStatistic.cxx:169
 RooAbsTestStatistic.cxx:170
 RooAbsTestStatistic.cxx:171
 RooAbsTestStatistic.cxx:172
 RooAbsTestStatistic.cxx:173
 RooAbsTestStatistic.cxx:174
 RooAbsTestStatistic.cxx:175
 RooAbsTestStatistic.cxx:176
 RooAbsTestStatistic.cxx:177
 RooAbsTestStatistic.cxx:178
 RooAbsTestStatistic.cxx:179
 RooAbsTestStatistic.cxx:180
 RooAbsTestStatistic.cxx:181
 RooAbsTestStatistic.cxx:182
 RooAbsTestStatistic.cxx:183
 RooAbsTestStatistic.cxx:184
 RooAbsTestStatistic.cxx:185
 RooAbsTestStatistic.cxx:186
 RooAbsTestStatistic.cxx:187
 RooAbsTestStatistic.cxx:188
 RooAbsTestStatistic.cxx:189
 RooAbsTestStatistic.cxx:190
 RooAbsTestStatistic.cxx:191
 RooAbsTestStatistic.cxx:192
 RooAbsTestStatistic.cxx:193
 RooAbsTestStatistic.cxx:194
 RooAbsTestStatistic.cxx:195
 RooAbsTestStatistic.cxx:196
 RooAbsTestStatistic.cxx:197
 RooAbsTestStatistic.cxx:198
 RooAbsTestStatistic.cxx:199
 RooAbsTestStatistic.cxx:200
 RooAbsTestStatistic.cxx:201
 RooAbsTestStatistic.cxx:202
 RooAbsTestStatistic.cxx:203
 RooAbsTestStatistic.cxx:204
 RooAbsTestStatistic.cxx:205
 RooAbsTestStatistic.cxx:206
 RooAbsTestStatistic.cxx:207
 RooAbsTestStatistic.cxx:208
 RooAbsTestStatistic.cxx:209
 RooAbsTestStatistic.cxx:210
 RooAbsTestStatistic.cxx:211
 RooAbsTestStatistic.cxx:212
 RooAbsTestStatistic.cxx:213
 RooAbsTestStatistic.cxx:214
 RooAbsTestStatistic.cxx:215
 RooAbsTestStatistic.cxx:216
 RooAbsTestStatistic.cxx:217
 RooAbsTestStatistic.cxx:218
 RooAbsTestStatistic.cxx:219
 RooAbsTestStatistic.cxx:220
 RooAbsTestStatistic.cxx:221
 RooAbsTestStatistic.cxx:222
 RooAbsTestStatistic.cxx:223
 RooAbsTestStatistic.cxx:224
 RooAbsTestStatistic.cxx:225
 RooAbsTestStatistic.cxx:226
 RooAbsTestStatistic.cxx:227
 RooAbsTestStatistic.cxx:228
 RooAbsTestStatistic.cxx:229
 RooAbsTestStatistic.cxx:230
 RooAbsTestStatistic.cxx:231
 RooAbsTestStatistic.cxx:232
 RooAbsTestStatistic.cxx:233
 RooAbsTestStatistic.cxx:234
 RooAbsTestStatistic.cxx:235
 RooAbsTestStatistic.cxx:236
 RooAbsTestStatistic.cxx:237
 RooAbsTestStatistic.cxx:238
 RooAbsTestStatistic.cxx:239
 RooAbsTestStatistic.cxx:240
 RooAbsTestStatistic.cxx:241
 RooAbsTestStatistic.cxx:242
 RooAbsTestStatistic.cxx:243
 RooAbsTestStatistic.cxx:244
 RooAbsTestStatistic.cxx:245
 RooAbsTestStatistic.cxx:246
 RooAbsTestStatistic.cxx:247
 RooAbsTestStatistic.cxx:248
 RooAbsTestStatistic.cxx:249
 RooAbsTestStatistic.cxx:250
 RooAbsTestStatistic.cxx:251
 RooAbsTestStatistic.cxx:252
 RooAbsTestStatistic.cxx:253
 RooAbsTestStatistic.cxx:254
 RooAbsTestStatistic.cxx:255
 RooAbsTestStatistic.cxx:256
 RooAbsTestStatistic.cxx:257
 RooAbsTestStatistic.cxx:258
 RooAbsTestStatistic.cxx:259
 RooAbsTestStatistic.cxx:260
 RooAbsTestStatistic.cxx:261
 RooAbsTestStatistic.cxx:262
 RooAbsTestStatistic.cxx:263
 RooAbsTestStatistic.cxx:264
 RooAbsTestStatistic.cxx:265
 RooAbsTestStatistic.cxx:266
 RooAbsTestStatistic.cxx:267
 RooAbsTestStatistic.cxx:268
 RooAbsTestStatistic.cxx:269
 RooAbsTestStatistic.cxx:270
 RooAbsTestStatistic.cxx:271
 RooAbsTestStatistic.cxx:272
 RooAbsTestStatistic.cxx:273
 RooAbsTestStatistic.cxx:274
 RooAbsTestStatistic.cxx:275
 RooAbsTestStatistic.cxx:276
 RooAbsTestStatistic.cxx:277
 RooAbsTestStatistic.cxx:278
 RooAbsTestStatistic.cxx:279
 RooAbsTestStatistic.cxx:280
 RooAbsTestStatistic.cxx:281
 RooAbsTestStatistic.cxx:282
 RooAbsTestStatistic.cxx:283
 RooAbsTestStatistic.cxx:284
 RooAbsTestStatistic.cxx:285
 RooAbsTestStatistic.cxx:286
 RooAbsTestStatistic.cxx:287
 RooAbsTestStatistic.cxx:288
 RooAbsTestStatistic.cxx:289
 RooAbsTestStatistic.cxx:290
 RooAbsTestStatistic.cxx:291
 RooAbsTestStatistic.cxx:292
 RooAbsTestStatistic.cxx:293
 RooAbsTestStatistic.cxx:294
 RooAbsTestStatistic.cxx:295
 RooAbsTestStatistic.cxx:296
 RooAbsTestStatistic.cxx:297
 RooAbsTestStatistic.cxx:298
 RooAbsTestStatistic.cxx:299
 RooAbsTestStatistic.cxx:300
 RooAbsTestStatistic.cxx:301
 RooAbsTestStatistic.cxx:302
 RooAbsTestStatistic.cxx:303
 RooAbsTestStatistic.cxx:304
 RooAbsTestStatistic.cxx:305
 RooAbsTestStatistic.cxx:306
 RooAbsTestStatistic.cxx:307
 RooAbsTestStatistic.cxx:308
 RooAbsTestStatistic.cxx:309
 RooAbsTestStatistic.cxx:310
 RooAbsTestStatistic.cxx:311
 RooAbsTestStatistic.cxx:312
 RooAbsTestStatistic.cxx:313
 RooAbsTestStatistic.cxx:314
 RooAbsTestStatistic.cxx:315
 RooAbsTestStatistic.cxx:316
 RooAbsTestStatistic.cxx:317
 RooAbsTestStatistic.cxx:318
 RooAbsTestStatistic.cxx:319
 RooAbsTestStatistic.cxx:320
 RooAbsTestStatistic.cxx:321
 RooAbsTestStatistic.cxx:322
 RooAbsTestStatistic.cxx:323
 RooAbsTestStatistic.cxx:324
 RooAbsTestStatistic.cxx:325
 RooAbsTestStatistic.cxx:326
 RooAbsTestStatistic.cxx:327
 RooAbsTestStatistic.cxx:328
 RooAbsTestStatistic.cxx:329
 RooAbsTestStatistic.cxx:330
 RooAbsTestStatistic.cxx:331
 RooAbsTestStatistic.cxx:332
 RooAbsTestStatistic.cxx:333
 RooAbsTestStatistic.cxx:334
 RooAbsTestStatistic.cxx:335
 RooAbsTestStatistic.cxx:336
 RooAbsTestStatistic.cxx:337
 RooAbsTestStatistic.cxx:338
 RooAbsTestStatistic.cxx:339
 RooAbsTestStatistic.cxx:340
 RooAbsTestStatistic.cxx:341
 RooAbsTestStatistic.cxx:342
 RooAbsTestStatistic.cxx:343
 RooAbsTestStatistic.cxx:344
 RooAbsTestStatistic.cxx:345
 RooAbsTestStatistic.cxx:346
 RooAbsTestStatistic.cxx:347
 RooAbsTestStatistic.cxx:348
 RooAbsTestStatistic.cxx:349
 RooAbsTestStatistic.cxx:350
 RooAbsTestStatistic.cxx:351
 RooAbsTestStatistic.cxx:352
 RooAbsTestStatistic.cxx:353
 RooAbsTestStatistic.cxx:354
 RooAbsTestStatistic.cxx:355
 RooAbsTestStatistic.cxx:356
 RooAbsTestStatistic.cxx:357
 RooAbsTestStatistic.cxx:358
 RooAbsTestStatistic.cxx:359
 RooAbsTestStatistic.cxx:360
 RooAbsTestStatistic.cxx:361
 RooAbsTestStatistic.cxx:362
 RooAbsTestStatistic.cxx:363
 RooAbsTestStatistic.cxx:364
 RooAbsTestStatistic.cxx:365
 RooAbsTestStatistic.cxx:366
 RooAbsTestStatistic.cxx:367
 RooAbsTestStatistic.cxx:368
 RooAbsTestStatistic.cxx:369
 RooAbsTestStatistic.cxx:370
 RooAbsTestStatistic.cxx:371
 RooAbsTestStatistic.cxx:372
 RooAbsTestStatistic.cxx:373
 RooAbsTestStatistic.cxx:374
 RooAbsTestStatistic.cxx:375
 RooAbsTestStatistic.cxx:376
 RooAbsTestStatistic.cxx:377
 RooAbsTestStatistic.cxx:378
 RooAbsTestStatistic.cxx:379
 RooAbsTestStatistic.cxx:380
 RooAbsTestStatistic.cxx:381
 RooAbsTestStatistic.cxx:382
 RooAbsTestStatistic.cxx:383
 RooAbsTestStatistic.cxx:384
 RooAbsTestStatistic.cxx:385
 RooAbsTestStatistic.cxx:386
 RooAbsTestStatistic.cxx:387
 RooAbsTestStatistic.cxx:388
 RooAbsTestStatistic.cxx:389
 RooAbsTestStatistic.cxx:390
 RooAbsTestStatistic.cxx:391
 RooAbsTestStatistic.cxx:392
 RooAbsTestStatistic.cxx:393
 RooAbsTestStatistic.cxx:394
 RooAbsTestStatistic.cxx:395
 RooAbsTestStatistic.cxx:396
 RooAbsTestStatistic.cxx:397
 RooAbsTestStatistic.cxx:398
 RooAbsTestStatistic.cxx:399
 RooAbsTestStatistic.cxx:400
 RooAbsTestStatistic.cxx:401
 RooAbsTestStatistic.cxx:402
 RooAbsTestStatistic.cxx:403
 RooAbsTestStatistic.cxx:404
 RooAbsTestStatistic.cxx:405
 RooAbsTestStatistic.cxx:406
 RooAbsTestStatistic.cxx:407
 RooAbsTestStatistic.cxx:408
 RooAbsTestStatistic.cxx:409
 RooAbsTestStatistic.cxx:410
 RooAbsTestStatistic.cxx:411
 RooAbsTestStatistic.cxx:412
 RooAbsTestStatistic.cxx:413
 RooAbsTestStatistic.cxx:414
 RooAbsTestStatistic.cxx:415
 RooAbsTestStatistic.cxx:416
 RooAbsTestStatistic.cxx:417
 RooAbsTestStatistic.cxx:418
 RooAbsTestStatistic.cxx:419
 RooAbsTestStatistic.cxx:420
 RooAbsTestStatistic.cxx:421
 RooAbsTestStatistic.cxx:422
 RooAbsTestStatistic.cxx:423
 RooAbsTestStatistic.cxx:424
 RooAbsTestStatistic.cxx:425
 RooAbsTestStatistic.cxx:426
 RooAbsTestStatistic.cxx:427
 RooAbsTestStatistic.cxx:428
 RooAbsTestStatistic.cxx:429
 RooAbsTestStatistic.cxx:430
 RooAbsTestStatistic.cxx:431
 RooAbsTestStatistic.cxx:432
 RooAbsTestStatistic.cxx:433
 RooAbsTestStatistic.cxx:434
 RooAbsTestStatistic.cxx:435
 RooAbsTestStatistic.cxx:436
 RooAbsTestStatistic.cxx:437
 RooAbsTestStatistic.cxx:438
 RooAbsTestStatistic.cxx:439
 RooAbsTestStatistic.cxx:440
 RooAbsTestStatistic.cxx:441
 RooAbsTestStatistic.cxx:442
 RooAbsTestStatistic.cxx:443
 RooAbsTestStatistic.cxx:444
 RooAbsTestStatistic.cxx:445
 RooAbsTestStatistic.cxx:446
 RooAbsTestStatistic.cxx:447
 RooAbsTestStatistic.cxx:448
 RooAbsTestStatistic.cxx:449
 RooAbsTestStatistic.cxx:450
 RooAbsTestStatistic.cxx:451
 RooAbsTestStatistic.cxx:452
 RooAbsTestStatistic.cxx:453
 RooAbsTestStatistic.cxx:454
 RooAbsTestStatistic.cxx:455
 RooAbsTestStatistic.cxx:456
 RooAbsTestStatistic.cxx:457
 RooAbsTestStatistic.cxx:458
 RooAbsTestStatistic.cxx:459
 RooAbsTestStatistic.cxx:460
 RooAbsTestStatistic.cxx:461
 RooAbsTestStatistic.cxx:462
 RooAbsTestStatistic.cxx:463
 RooAbsTestStatistic.cxx:464
 RooAbsTestStatistic.cxx:465
 RooAbsTestStatistic.cxx:466
 RooAbsTestStatistic.cxx:467
 RooAbsTestStatistic.cxx:468
 RooAbsTestStatistic.cxx:469
 RooAbsTestStatistic.cxx:470
 RooAbsTestStatistic.cxx:471
 RooAbsTestStatistic.cxx:472
 RooAbsTestStatistic.cxx:473
 RooAbsTestStatistic.cxx:474
 RooAbsTestStatistic.cxx:475
 RooAbsTestStatistic.cxx:476
 RooAbsTestStatistic.cxx:477
 RooAbsTestStatistic.cxx:478
 RooAbsTestStatistic.cxx:479
 RooAbsTestStatistic.cxx:480
 RooAbsTestStatistic.cxx:481
 RooAbsTestStatistic.cxx:482
 RooAbsTestStatistic.cxx:483
 RooAbsTestStatistic.cxx:484
 RooAbsTestStatistic.cxx:485
 RooAbsTestStatistic.cxx:486
 RooAbsTestStatistic.cxx:487
 RooAbsTestStatistic.cxx:488
 RooAbsTestStatistic.cxx:489
 RooAbsTestStatistic.cxx:490
 RooAbsTestStatistic.cxx:491
 RooAbsTestStatistic.cxx:492
 RooAbsTestStatistic.cxx:493
 RooAbsTestStatistic.cxx:494
 RooAbsTestStatistic.cxx:495