32 #include "TDirectory.h"
60 for (map<string,RooAbsDataStore*>::iterator
iter=inputData.begin() ;
iter!=inputData.end() ; ++
iter) {
73 RooAbsDataStore(other,newname), _indexCat(other._indexCat), _curStore(other._curStore), _curIndex(other._curIndex), _ownComps(
kTRUE)
87 RooAbsDataStore(other,vars,newname), _indexCat(other._indexCat), _curStore(other._curStore), _curIndex(other._curIndex), _ownComps(
kTRUE)
111 map<int,RooAbsDataStore*>::const_iterator
iter ;
113 delete iter->second ;
137 map<int,RooAbsDataStore*>::const_iterator
iter ;
139 iter->second->recalculateCache(proj,firstEvent,lastEvent,stepSize,skipZeroWeights) ;
149 map<int,RooAbsDataStore*>::const_iterator
iter ;
151 ret |= iter->second->hasFilledCache() ;
161 map<int,RooAbsDataStore*>::const_iterator
iter ;
163 iter->second->forceCacheUpdate() ;
176 return subset->
fill() ;
188 map<int,RooAbsDataStore*>::const_iterator
iter ;
190 sum+= iter->second->sumEntries() ;
205 map<int,RooAbsDataStore*>::const_iterator
iter ;
207 if (idx>=(offset+iter->second->numEntries())) {
208 offset += iter->second->numEntries() ;
276 map<int,RooAbsDataStore*>::const_iterator
iter ;
278 if (iter->second->isWeighted())
return kTRUE ;
288 throw(std::string(
"RooCompositeDataSore::loadValues() NOT IMPLEMENTED")) ;
304 coutE(
InputArguments) <<
"RooCompositeDataStore::changeObservableName(" <<
GetName() <<
" no observable " << from <<
" in this dataset" << endl ;
313 map<int,RooAbsDataStore*>::const_iterator
iter ;
315 ret |= iter->second->changeObservableName(from,to) ;
330 map<int,RooAbsDataStore*>::const_iterator
iter ;
332 ret = iter->second->addColumn(newVar,adjustRange) ;
349 map<int,RooAbsDataStore*>::const_iterator
iter ;
351 ret = iter->second->addColumns(varList) ;
366 throw string(
"RooCompositeDataStore::merge() is not implemented yet") ;
378 for (
int i=0 ; i<nevt ; i++) {
391 map<int,RooAbsDataStore*>::const_iterator
iter ;
393 n += iter->second->numEntries() ;
405 map<int,RooAbsDataStore*>::const_iterator
iter ;
407 iter->second->reset() ;
417 map<int,RooAbsDataStore*>::const_iterator
iter ;
419 iter->second->cacheArgs(owner,newVarSet,nset,skipZeroWeights) ;
429 map<int,RooAbsDataStore*>::const_iterator
iter ;
432 iter->second->setArgStatus(*subset,active) ;
446 map<int,RooAbsDataStore*>::const_iterator
iter ;
448 iter->second->attachCache(newOwner,inCachedVars) ;
459 map<int,RooAbsDataStore*>::const_iterator
iter ;
461 iter->second->resetCache() ;
472 map<int,RooAbsDataStore*>::const_iterator
iter ;
474 iter->second->attachBuffers(extObs);
485 map<int,RooAbsDataStore*>::const_iterator
iter ;
487 iter->second->resetBuffers();
497 cout <<
"RooCompositeDataStore::dump()" << endl ;
498 map<int,RooAbsDataStore*>::const_iterator
iter ;
500 cout <<
"state number " << iter->first <<
" has store " << iter->second->IsA()->GetName() <<
" with variables " << *iter->second->get() ;
501 if (iter->second->isWeighted()) cout <<
" and is weighted " ;
virtual Int_t getIndex() const
Return index number of current state.
virtual Double_t weight() const =0
virtual Bool_t isWeighted() const
RooAbsCollection * selectCommon(const RooAbsCollection &refColl) const
Create a subset of the current collection, consisting only of those elements that are contained as we...
virtual Int_t numEntries() const
virtual Bool_t setIndex(Int_t index, Bool_t printError=kTRUE)
Set value by specifying the index code of the desired state.
virtual ~RooCompositeDataStore()
Destructor.
virtual const RooArgSet * get() const
virtual const RooArgSet * get(Int_t index) const =0
virtual void setArgStatus(const RooArgSet &set, Bool_t active)
ClassImp(RooCompositeDataStore)
virtual Int_t numEntries() const =0
virtual void attachBuffers(const RooArgSet &extObs)
std::map< Int_t, RooAbsDataStore * > _dataMap
std::map< std::string, std::string >::const_iterator iter
virtual Int_t fill()
Forward fill request to appropriate subset.
Bool_t _ownComps
Index associated with current event.
if on multiple lines(like in C++).**The" * configuration fragment. * * The "import myobject continue
Parses the configuration file.
virtual Bool_t valid() const
Return true if currently loaded coordinate is considered valid within the current range definitions o...
virtual void forceCacheUpdate()
virtual void resetBuffers()
virtual Double_t weightError(RooAbsData::ErrorType etype=RooAbsData::Poisson) const
virtual void resetCache()
RooAbsArg * find(const char *name) const
Find object with given name in list.
virtual Bool_t hasFilledCache() const
virtual Bool_t changeObservableName(const char *from, const char *to)
Change name of internal observable named 'from' into 'to'.
void SetName(const char *name)
Change (i.e.
virtual const char * GetName() const
Returns name of object.
void loadValues(const RooAbsDataStore *tds, const RooFormulaVar *select=0, const char *rangeName=0, Int_t nStart=0, Int_t nStop=2000000000)
virtual RooAbsArg * addColumn(RooAbsArg &var, Bool_t adjustRange=kTRUE)
WVE ownership issue here!! Caller (a RooAbsData) should take ownership of all arguments, but only does for the first one here...
virtual void cacheArgs(const RooAbsArg *owner, RooArgSet &varSet, const RooArgSet *nset=0, Bool_t skipZeroWeights=kFALSE)
void attachCache(const RooAbsArg *newOwner, const RooArgSet &cachedVars)
Initialize cache of dataset: attach variables of cache ArgSet to the corresponding TTree branches...
virtual RooArgSet * addColumns(const RooArgList &varList)
WVE ownership issue here!! Caller (a RooAbsData) should take ownership of all arguments, but only does for the first one here...
RooAbsCollection & assignValueOnly(const RooAbsCollection &other, Bool_t oneSafe=kFALSE)
The assignment operator sets the value of any argument in our set that also appears in the other set...
Int_t _curIndex
Datastore associated with current event.
RooAbsDataStore * merge(const RooArgSet &allvars, std::list< RooAbsDataStore * > dstoreList)
virtual Double_t weightError(RooAbsData::ErrorType etype=RooAbsData::Poisson) const =0
float type_of_call hi(const int &, const int &)
RooAbsArg is the common abstract base class for objects that represent a value (of arbitrary type) an...
virtual Double_t sumEntries() const
Forward fill request to appropriate subset.
virtual Double_t weight() const
virtual void append(RooAbsDataStore &other)
RooAbsDataStore * _curStore
virtual Bool_t add(const RooAbsArg &var, Bool_t silent=kFALSE)
Add element to non-owning set.
virtual void recalculateCache(const RooArgSet *, Int_t, Int_t, Int_t, Bool_t)
Forward recalculate request to all subsets.
const RooCatType * lookupType(Int_t index, Bool_t printError=kFALSE) const
Find our type corresponding to the specified index, or return 0 for no match.