ROOT » ROOFIT » ROOFITCORE » RooFactoryWSTool

class RooFactoryWSTool: public TNamed, public RooPrintable



RooFactoryWSTool is a clase like TTree::MakeClass() that generates skeleton code for RooAbsPdf and RooAbsReal functions given a list of input parameter names. The factory can also compile the generated code on the fly, and on request also immediate instantiate objects.

Function Members (Methods)

public:
virtual~RooFactoryWSTool()
voidTObject::AbstractMethod(const char* method) const
RooAddPdf*add(const char* objName, const char* specList, Bool_t recursiveCoefs = kFALSE)
RooAddition*addfunc(const char* objName, const char* specList)
RooRealSumPdf*amplAdd(const char* objName, const char* specList)
virtual voidTObject::AppendPad(Option_t* option = "")
static RooAbsArg&as_ARG(UInt_t idx)
static RooCategory&as_CAT(UInt_t idx)
static RooAbsCategory&as_CATFUNC(UInt_t idx)
static RooAbsCategoryLValue&as_CATLV(UInt_t idx)
static RooAbsData&as_DATA(UInt_t idx)
static RooDataHist&as_DHIST(UInt_t idx)
static Double_tas_DOUBLE(UInt_t idx)
static Double_tas_DOUBLE(UInt_t idx, Double_t defVal)
static RooDataSet&as_DSET(UInt_t idx)
static RooAbsReal&as_FUNC(UInt_t idx)
static Int_tas_INT(UInt_t idx)
static Int_tas_INT(UInt_t idx, Int_t defVal)
static RooArgListas_LIST(UInt_t idx)
static TObject&as_OBJ(UInt_t idx)
static RooAbsPdf&as_PDF(UInt_t idx)
static RooResolutionModel&as_RMODEL(UInt_t idx)
static RooArgSetas_SET(UInt_t idx)
static const char*as_STRING(UInt_t idx)
static RooRealVar&as_VAR(UInt_t idx)
static RooAbsRealLValue&as_VARLV(UInt_t idx)
RooAbsArg&asARG(const char*)
RooCategory&asCAT(const char*)
RooAbsCategory&asCATFUNC(const char*)
RooAbsCategoryLValue&asCATLV(const char*)
RooAbsData&asDATA(const char*)
RooDataHist&asDHIST(const char*)
Double_tasDOUBLE(const char*)
RooDataSet&asDSET(const char*)
RooAbsReal&asFUNC(const char*)
Int_tasINT(const char*)
RooArgListasLIST(const char*)
TObject&asOBJ(const char*)
RooAbsPdf&asPDF(const char*)
RooResolutionModel&asRMODEL(const char*)
RooArgSetasSET(const char*)
const char*asSTRING(const char*)
RooRealVar&asVAR(const char*)
RooAbsRealLValue&asVARLV(const char*)
const char*autoClassNamePostFix() const
virtual voidTObject::Browse(TBrowser* b)
static TClass*Class()
virtual const char*TObject::ClassName() const
virtual voidTNamed::Clear(Option_t* option = "")
virtual TObject*TNamed::Clone(const char* newname = "") const
virtual Int_tTNamed::Compare(const TObject* obj) const
virtual voidTNamed::Copy(TObject& named) const
RooAbsArg*createArg(const char* className, const char* objName, const char* varList)
RooCategory*createCategory(const char* name, const char* stateNameList = 0)
RooRealVar*createVariable(const char* name, Double_t xmin, Double_t xmax)
vector<string>ctorArgs(const char* className)
virtual Int_tRooPrintable::defaultPrintContents(Option_t* opt) const
static ostream&RooPrintable::defaultPrintStream(ostream* os = 0)
virtual RooPrintable::StyleOptionRooPrintable::defaultPrintStyle(Option_t* opt) const
virtual voidTObject::Delete(Option_t* option = "")MENU
virtual Int_tTObject::DistancetoPrimitive(Int_t px, Int_t py)
virtual voidTObject::Draw(Option_t* option = "")
virtual voidTObject::DrawClass() constMENU
virtual TObject*TObject::DrawClone(Option_t* option = "") constMENU
virtual voidTObject::Dump() constMENU
virtual voidTObject::Error(const char* method, const char* msgfmt) const
virtual voidTObject::Execute(const char* method, const char* params, Int_t* error = 0)
virtual voidTObject::Execute(TMethod* method, TObjArray* params, Int_t* error = 0)
virtual voidTObject::ExecuteEvent(Int_t event, Int_t px, Int_t py)
virtual voidTObject::Fatal(const char* method, const char* msgfmt) const
virtual voidTNamed::FillBuffer(char*& buffer)
virtual TObject*TObject::FindObject(const char* name) const
virtual TObject*TObject::FindObject(const TObject* obj) const
virtual Option_t*TObject::GetDrawOption() const
static Long_tTObject::GetDtorOnly()
virtual const char*TObject::GetIconName() const
virtual const char*TNamed::GetName() const
virtual char*TObject::GetObjectInfo(Int_t px, Int_t py) const
static Bool_tTObject::GetObjectStat()
virtual Option_t*TObject::GetOption() const
virtual const char*TNamed::GetTitle() const
virtual UInt_tTObject::GetUniqueID() const
virtual Bool_tTObject::HandleTimer(TTimer* timer)
virtual ULong_tTNamed::Hash() const
virtual voidTObject::Info(const char* method, const char* msgfmt) const
virtual Bool_tTObject::InheritsFrom(const char* classname) const
virtual Bool_tTObject::InheritsFrom(const TClass* cl) const
virtual voidTObject::Inspect() constMENU
voidTObject::InvertBit(UInt_t f)
virtual TClass*IsA() const
virtual Bool_tTObject::IsEqual(const TObject* obj) const
virtual Bool_tTObject::IsFolder() const
Bool_tTObject::IsOnHeap() const
virtual Bool_tTNamed::IsSortable() const
Bool_tTObject::IsZombie() const
voidlogError()
virtual voidTNamed::ls(Option_t* option = "") const
voidTObject::MayNotUse(const char* method) const
static voidRooPrintable::nameFieldLength(Int_t newLen)
virtual Bool_tTObject::Notify()
voidTObject::Obsolete(const char* method, const char* asOfVers, const char* removedFromVers) const
voidTObject::operator delete(void* ptr)
voidTObject::operator delete(void* ptr, void* vp)
voidTObject::operator delete[](void* ptr)
voidTObject::operator delete[](void* ptr, void* vp)
void*TObject::operator new(size_t sz)
void*TObject::operator new(size_t sz, void* vp)
void*TObject::operator new[](size_t sz)
void*TObject::operator new[](size_t sz, void* vp)
RooFactoryWSTool&operator=(const RooFactoryWSTool&)
virtual voidTObject::Paint(Option_t* option = "")
virtual voidTObject::Pop()
virtual voidTNamed::Print(Option_t* option = "") const
virtual voidRooPrintable::printAddress(ostream& os) const
virtual voidRooPrintable::printArgs(ostream& os) const
virtual voidRooPrintable::printClassName(ostream& os) const
virtual voidRooPrintable::printExtras(ostream& os) const
virtual voidRooPrintable::printMultiline(ostream& os, Int_t contents, Bool_t verbose = kFALSE, TString indent = "") const
virtual voidRooPrintable::printName(ostream& os) const
virtual voidRooPrintable::printStream(ostream& os, Int_t contents, RooPrintable::StyleOption style, TString indent = "") const
virtual voidRooPrintable::printTitle(ostream& os) const
virtual voidRooPrintable::printTree(ostream& os, TString indent = "") const
virtual voidRooPrintable::printValue(ostream& os) const
RooAbsArg*process(const char* expr)
stringprocessExpression(const char* expr)
RooProdPdf*prod(const char* objName, const char* pdfList)
RooProduct*prodfunc(const char* objName, const char* pdfList)
virtual Int_tTObject::Read(const char* name)
virtual voidTObject::RecursiveRemove(TObject* obj)
static voidregisterSpecial(const char* typeName, RooFactoryWSTool::IFace* iface)
voidTObject::ResetBit(UInt_t f)
RooFactoryWSTool(RooWorkspace& ws)
virtual voidTObject::SaveAs(const char* filename = "", Option_t* option = "") constMENU
virtual voidTObject::SavePrimitive(ostream& out, Option_t* option = "")
voidsetAutoClassNamePostFix(const char* pfix)
voidTObject::SetBit(UInt_t f)
voidTObject::SetBit(UInt_t f, Bool_t set)
virtual voidTObject::SetDrawOption(Option_t* option = "")MENU
static voidTObject::SetDtorOnly(void* obj)
virtual voidTNamed::SetName(const char* name)MENU
virtual voidTNamed::SetNameTitle(const char* name, const char* title)
static voidTObject::SetObjectStat(Bool_t stat)
virtual voidTNamed::SetTitle(const char* title = "")MENU
virtual voidTObject::SetUniqueID(UInt_t uid)
virtual voidShowMembers(TMemberInspector& insp) const
RooSimultaneous*simul(const char* objName, const char* indexCat, const char* pdfMap)
virtual Int_tTNamed::Sizeof() const
vector<string>splitFunctionArgs(const char* funcExpr)
virtual voidStreamer(TBuffer&)
voidStreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
virtual voidTObject::SysError(const char* method, const char* msgfmt) const
Bool_tTObject::TestBit(UInt_t f) const
Int_tTObject::TestBits(UInt_t f) const
virtual voidTObject::UseCurrentStyle()
virtual voidTObject::Warning(const char* method, const char* msgfmt) const
virtual Int_tTObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
virtual Int_tTObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0) const
RooWorkspace&ws()
protected:
static voidcheckIndex(UInt_t index)
Bool_tcheckSyntax(const char* arg)
voidclearError()
virtual voidTObject::DoError(int level, const char* location, const char* fmt, va_list va) const
Int_terrorCount()
static map<string,RooFactoryWSTool::IFace*>&hooks()
voidTObject::MakeZombie()
static RooFactoryWSTool*of()
stringprocessAliasExpression(const char* arg)
stringprocessCompositeExpression(const char* arg)
stringprocessCreateArg(string& func, vector<string>& args)
stringprocessCreateVar(string& func, vector<string>& args)
stringprocessListExpression(const char* arg)
stringprocessMetaArg(string& func, vector<string>& args)
stringprocessSingleExpression(const char* arg)
TClass*resolveClassName(const char* className)
RooFactoryWSTool(const RooFactoryWSTool&)
stringvarTag(string& func, vector<string>& args)

Data Members

public:
static RooPrintable::ContentsOptionRooPrintable::kAddress
static RooPrintable::ContentsOptionRooPrintable::kArgs
static TObject::(anonymous)TObject::kBitMask
static TObject::EStatusBitsTObject::kCanDelete
static TObject::EStatusBitsTObject::kCannotPick
static RooPrintable::ContentsOptionRooPrintable::kClassName
static RooPrintable::ContentsOptionRooPrintable::kCollectionHeader
static RooPrintable::ContentsOptionRooPrintable::kExtras
static TObject::EStatusBitsTObject::kHasUUID
static RooPrintable::StyleOptionRooPrintable::kInline
static TObject::EStatusBitsTObject::kInvalidObject
static TObject::(anonymous)TObject::kIsOnHeap
static TObject::EStatusBitsTObject::kIsReferenced
static TObject::EStatusBitsTObject::kMustCleanup
static RooPrintable::ContentsOptionRooPrintable::kName
static TObject::EStatusBitsTObject::kNoContextMenu
static TObject::(anonymous)TObject::kNotDeleted
static TObject::EStatusBitsTObject::kObjInCanvas
static TObject::(anonymous)TObject::kOverwrite
static TObject::(anonymous)TObject::kSingleKey
static RooPrintable::StyleOptionRooPrintable::kSingleLine
static RooPrintable::StyleOptionRooPrintable::kStandard
static RooPrintable::ContentsOptionRooPrintable::kTitle
static RooPrintable::StyleOptionRooPrintable::kTreeStructure
static RooPrintable::ContentsOptionRooPrintable::kValue
static RooPrintable::StyleOptionRooPrintable::kVerbose
static TObject::(anonymous)TObject::kWriteDelete
static TObject::(anonymous)TObject::kZombie
protected:
vector<string>_args
string_autoClassPostFix
stack<string>_autoNamePrefix
Int_t_errorCountError counter for a given expression processing
static map<string,RooFactoryWSTool::IFace*>*_hooks
static Int_tRooPrintable::_nameLength
static RooFactoryWSTool*_of
map<string,string>_typeAliases
RooWorkspace*_ws! Associated workspace
TStringTNamed::fNameobject identifier
TStringTNamed::fTitleobject title

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

RooFactoryWSTool(RooWorkspace& ws)
 Default constructor
~RooFactoryWSTool()
 Destructor
RooRealVar* createVariable(const char* name, Double_t xmin, Double_t xmax)
 Low-level factory interface for creating a RooRealVar with a given range and initial value
RooCategory* createCategory(const char* name, const char* stateNameList = 0)
 Low-level factory interface for creating a RooCategory with a given list of state names. The State name list
 can be of the form 'name1,name2,name3' or of the form 'name1=id1,name2=id2,name3=id3'
RooAbsArg* createArg(const char* className, const char* objName, const char* varList)
 Low-level factory interface for creating a RooAbsPdf of a given class with a given list of input variables
 The variable list varList should be of the form "a,b,c" where the interpretation of the argument is
 dependent on the p.d.f. Set and List arguments can be passed by substituting a single argument with
 the form (a,b,c), i.e. one can set varList to "x,(a0,a1,a2)" to pass a RooAbsReal and a RooArgSet as arguments.
vector<string> ctorArgs(const char* className)
RooAddPdf* add(const char* objName, const char* specList, Bool_t recursiveCoefs = kFALSE)
RooRealSumPdf* amplAdd(const char* objName, const char* specList)
RooProdPdf* prod(const char* objName, const char* pdfList)
RooSimultaneous* simul(const char* objName, const char* indexCat, const char* pdfMap)
RooAddition* addfunc(const char* objName, const char* specList)
RooProduct* prodfunc(const char* objName, const char* pdfList)
RooAbsArg* process(const char* expr)
 Process high-level object creation syntax
 Accepted forms of syntax are


 Creating variables

 x[-10,10]             -  Create variable x with given range and put it in workspace
 x[3,-10,10]           -  Create variable x with given range and initial value and put it in workspace
 x[3]                  -  Create variable x with given constant value

 <numeric literal>     - Numeric literal expressions (0.5, -3 etc..) are converted to a RooConst(<numeric literal>)
                         where ever a RooAbsReal or RooAbsArg argument is expected

 Creating categories

 c[lep,kao,nt1,nt2]    -  Create category c with given state names
 tag[B0=1,B0bar=-1]    -  Create category tag with given state names and index assignments


 Creating functions and p.d.f.s

 MyPdf::g(x,m,s)       - Create p.d.f or function of type MyPdf with name g with argument x,m,s
                         Interpretation and number of arguments are mapped to the constructor arguments of the class
                         (after the name and title).

 MyPdf(x,m,s)          - As above, but with an implicitly defined (unique) object name


 Creating sets and lists (to be used as inputs above)

 {a,b,c}               - Create RooArgSet or RooArgList (as determined by context) from given contents



 Objects that are not created, are assumed to exist in the workspace
 Object creation expressions as shown above can be nested, e.g. one can do

   RooGaussian::g(x[-10,10],m[0],3)

 to create a p.d.f and its variables in one go. This nesting can be applied recursively e.g.

   SUM::model( f[0.5,0,1] * RooGaussian::g( x[-10,10], m[0], 3] ),
                            RooChebychev::c( x, {a0[0.1],a1[0.2],a2[-0.3]} ))

 creates the sum of a Gaussian and a Chebychev and all its variables


 A seperate series of operator meta-type exists to simplify the construction of composite expressions
 meta-types in all capitals (SUM) create p.d.f.s, meta types in lower case (sum) create
 functions.


 SUM::name(f1*pdf1,f2*pdf2,pdf3]  -- Create sum p.d.f name with value f1*pdf1+f2*pdf2+(1-f1-f2)*pdf3
 RSUM::name(f1*pdf1,f2*pdf2,pdf3] -- Create recursive sum p.d.f. name with value f1*pdf1 + (1-f1)(f2*pdf2 + (1-f2)pdf3)
 ASUM::name(f1*amp1,f2*amp2,amp3] -- Create sum p.d.f. name with value f1*amp1+f2*amp2+(1-f1-f2)*amp3 where amplX are amplitudes of type RooAbsReal
 sum::name(a1,a2,a3]              -- Create sum function with value a1+a2+a3
 sum::name(a1*b1,a2*b2,a3*b 3]    -- Create sum function with value a1*b1+a2*b2+a3*b3

 PROD::name(pdf1,pdf2]            -- Create product of p.d.f with 'name' with given input p.d.fs
 PROD::name(pdf1|x,pdf2]          -- Create product of conditional p.d.f. pdf1 given x and pdf2
 prod::name(a,b,c]                -- Create production function with value a*b*c

 SIMUL::name(cat,a=pdf1,b=pdf2]   -- Create simultaneous p.d.f index category cat. Make pdf1 to state a, pdf2 to state b

 EXPR::name('expr',var,...]       -- Create an generic p.d.f that interprets the given expression
 expr::name('expr',var,...]       -- Create an generic function that interprets the given expression


 The functionality of high level object creation tools like RooSimWSTool, RooCustomizer and RooClassFactory
 is also interfaced through meta-types in the factory


 Interface to RooSimWSTool

 SIMCLONE::name( modelPdf, $ParamSplit(...),
                 $ParamSplitConstrained(...), $Restrict(...) ]            -- Clone-and-customize modelPdf according to ParamSplit and ParamSplitConstrained()
                                                                             specifications and return a RooSimultaneous p.d.f. of all built clones

 MSIMCLONE::name( masterIndex,
                  $AddPdf(mstate1, modelPdf1, $ParamSplit(...)),
                  $AddPdf(mstate2,modelPdf2),...) ]                       -- Clone-and-customize multiple models (modelPdf1,modelPdf2) according to ParamSplit and
                                                                             ParamSplitConstrained() specifications and return a RooSimultaneous p.d.f. of all built clones,
                                                                             using the specified master index to map prototype p.d.f.s to master states
 Interface to RooCustomizer

 EDIT::name( orig, substNode=origNode), ... ]                             -- Create a clone of input object orig, with the specified replacements operations executed
 EDIT::name( orig, origNode=$REMOVE(), ... ]                              -- Create clone of input removing term origNode from all PROD() terms that contained it
 EDIT::name( orig, origNode=$REMOVE(prodname,...), ... ]                  -- As above, but restrict removal of origNode to PROD term(s) prodname,...


 Interface to RooClassFactory

 CEXPR::name('expr',var,...]       -- Create an custom compiled p.d.f that evaluates the given expression
 cexpr::name('expr',var,...]       -- Create an custom compiled function that evaluates the given expression


 $MetaType(...)        - Meta argument that does not result in construction of an object but is used logically organize
                         input arguments in certain operator p.d.f. constructions. The defined meta arguments are context dependent.

                         The only meta argument that is defined globally is $Alias(typeName,aliasName) to
                         define aliases for type names. For the definition of meta arguments in operator p.d.f.s
                         see the definitions below
std::string processExpression(const char* expr)
 Process a single high-level expression or list of
 expressions. The returned string a the reduced expression where
 all inline object creations have been executed and substituted
 with the name of the created object

 e.g. 'RooGaussian::g(x,m,s)' --> 'g'
      '{x(-10,10),s}          --> '{x,s}'
std::string processCompositeExpression(const char* arg)
 Process a single composite expression

 e.g. 'A=RooGaussian::g[x,m,s]' --> 'A=g'
 e.g. 'f[0,1]*RooGaussian::g[x,m,s]' --> 'f*g'
 e.g. 'RooGaussian::g(x,y,s)|x' --> g|x'
 e.g. '$MetaArg(RooGaussian::g[x,m,s],blah)' --> '$MetaArg(g,blah)'
std::string processSingleExpression(const char* arg)
 Process a single high-level expression. The returned string a the reduced
 expression where all inline object creations have been executed and substituted
 with the name of the created object

 e.g. 'RooGaussian::g(x,m,s)' --> 'g'
 e.g. 'x[-10,10]' --> 'x'
string processListExpression(const char* arg)
 Process a list of high-level expression. The returned string a the reduced
 expression list where all inline object creations have been executed and substituted
 with the name of the created object

 E.g.   '{x(-10,10),s}  --> '{x,s}'
string processAliasExpression(const char* arg)
 Parse token
TClass* resolveClassName(const char* className)
string varTag(string& func, vector<string>& args)
string processCreateVar(string& func, vector<string>& args)
 Glue function between high-level syntax and low-level factory call to createVariable:
 Process a parsed call to create a variable named 'func'

 If initial token is non-numeric, a RooCategory will be created, and the args are interpreted
 as either state names or 'name=id' assignments. Otherwise a RooRealvar is created and the
 arg list is interpreted as follows:
 If list has two args, these are interpreted as xmin,xmax
 If list has three args, these are interpreted as xinit,xmin,xmax
 If list has one arg, this is interpreted as xinit and the variable is set as constant
string processCreateArg(string& func, vector<string>& args)
 Glue function between high-level syntax and low-level factory call to createArg:
 Process a parsed call to create a p.d.f named func

 The func arg is interpreted as ClassName::ObjectName and the arglist is passed
 verbatim to createArg. The received arglist is expected to be fully reduced (i.e.
 all inline object creations must have been compiled)
std::string processMetaArg(string& func, vector<string>& args)
 Concatenate list of args into comma separated string
vector<string> splitFunctionArgs(const char* funcExpr)
 Allocate and fill work buffer
Bool_t checkSyntax(const char* arg)
 Perform basic syntax on given factory expression. If function returns
 true syntax errors are found.
void checkIndex(UInt_t index)
RooAbsArg& asARG(const char* )
 CINT constructor interface, return constructor string argument #idx as RooAbsArg reference found in workspace
RooAbsReal& asFUNC(const char* )
 CINT constructor interface, return constructor string argument #idx as RooAbsReal reference found in workspace
RooAbsRealLValue& asVARLV(const char* )
 CINT constructor interface, return constructor string argument #idx as RooAbsRealLValue reference found in workspace
RooRealVar& asVAR(const char* )
 CINT constructor interface, return constructor string argument #idx as RooRealVar reference found in workspace
RooAbsPdf& asPDF(const char* )
 CINT constructor interface, return constructor string argument #idx as RooAbsPdf reference found in workspace
RooResolutionModel& asRMODEL(const char* )
 CINT constructor interface, return constructor string argument #idx as RooResolutionModel reference found in workspace
RooAbsCategory& asCATFUNC(const char* )
 CINT constructor interface, return constructor string argument #idx as RooAbsCategory reference found in workspace
RooAbsCategoryLValue& asCATLV(const char* )
 CINT constructor interface, return constructor string argument #idx as RooAbsCategoryLValue reference found in workspace
RooCategory& asCAT(const char* )
 CINT constructor interface, return constructor string argument #idx as RooCategory reference found in workspace
RooArgSet asSET(const char* )
 CINT constructor interface, return constructor string argument #idx as RooArgSet of objects found in workspace
RooArgList asLIST(const char* )
 CINT constructor interface, return constructor string argument #idx as RooArgList of objects found in workspace
RooAbsData& asDATA(const char* )
 CINT constructor interface, return constructor string argument #idx as RooAbsData object found in workspace
RooDataHist& asDHIST(const char* )
 CINT constructor interface, return constructor string argument #idx as RooDataHist object found in workspace
RooDataSet& asDSET(const char* )
 CINT constructor interface, return constructor string argument #idx as RooDataSet object found in workspace
TObject& asOBJ(const char* )
const char* asSTRING(const char* )
 CINT constructor interface, return constructor string argument #idx as const char*
Int_t asINT(const char* )
 CINT constructor interface, return constructor string argument #idx as Int_t
Double_t asDOUBLE(const char* )
 CINT constructor interface, return constructor string argument #idx as Double_t
void registerSpecial(const char* typeName, RooFactoryWSTool::IFace* iface)
 Register foreign special objects in factory
RooFactoryWSTool* of()
RooFactoryWSTool(RooWorkspace& ws)
 Constructors, assignment etc
RooWorkspace& ws()
{ return *_ws ; }
RooAbsArg& as_ARG(UInt_t idx)
 --- Internal stuff that must be public so that CINT can access it ---
 CINT constructor interface
{ checkIndex(idx) ; return of()->of()->asARG(of()->_args[idx].c_str()) ; }
RooAbsPdf& as_PDF(UInt_t idx)
{ checkIndex(idx) ; return of()->asPDF(of()->_args[idx].c_str()) ; }
RooAbsReal& as_FUNC(UInt_t idx)
{ checkIndex(idx) ; return of()->asFUNC(of()->_args[idx].c_str()) ; }
RooRealVar& as_VAR(UInt_t idx)
{ checkIndex(idx) ; return of()->asVAR(of()->_args[idx].c_str()) ; }
RooAbsRealLValue& as_VARLV(UInt_t idx)
{ checkIndex(idx) ; return of()->asVARLV(of()->_args[idx].c_str()) ; }
RooResolutionModel& as_RMODEL(UInt_t idx)
{ checkIndex(idx) ; return of()->asRMODEL(of()->_args[idx].c_str()) ; }
RooCategory& as_CAT(UInt_t idx)
{ checkIndex(idx) ; return of()->asCAT(of()->_args[idx].c_str()) ; }
RooAbsCategoryLValue& as_CATLV(UInt_t idx)
{ checkIndex(idx) ; return of()->asCATLV(of()->_args[idx].c_str()) ; }
RooAbsCategory& as_CATFUNC(UInt_t idx)
{ checkIndex(idx) ; return of()->asCATFUNC(of()->_args[idx].c_str()) ; }
RooArgSet as_SET(UInt_t idx)
{ checkIndex(idx) ; return of()->asSET(of()->_args[idx].c_str()) ; }
RooArgList as_LIST(UInt_t idx)
{ checkIndex(idx) ; return of()->asLIST(of()->_args[idx].c_str()) ; }
RooAbsData& as_DATA(UInt_t idx)
{ checkIndex(idx) ; return of()->asDATA(of()->_args[idx].c_str()) ; }
RooDataHist& as_DHIST(UInt_t idx)
{ checkIndex(idx) ; return of()->asDHIST(of()->_args[idx].c_str()) ; }
RooDataSet& as_DSET(UInt_t idx)
{ checkIndex(idx) ; return of()->asDSET(of()->_args[idx].c_str()) ; }
TObject& as_OBJ(UInt_t idx)
{ checkIndex(idx) ; return of()->asOBJ(of()->_args[idx].c_str()) ; }
const char* as_STRING(UInt_t idx)
{ checkIndex(idx) ; return of()->asSTRING(of()->_args[idx].c_str()) ; }
Int_t as_INT(UInt_t idx)
{ checkIndex(idx) ; return of()->asINT(of()->_args[idx].c_str()) ; }
Double_t as_DOUBLE(UInt_t idx)
{ checkIndex(idx) ; return of()->asDOUBLE(of()->_args[idx].c_str()) ; }
Int_t as_INT(UInt_t idx, Int_t defVal)
{ checkIndex(idx) ; if (idx>of()->_args.size()-1) return defVal ; return of()->asINT(of()->_args[idx].c_str()) ; }
Double_t as_DOUBLE(UInt_t idx, Double_t defVal)
{ checkIndex(idx) ; if (idx>of()->_args.size()-1) return defVal ; return of()->asDOUBLE(of()->_args[idx].c_str()) ; }
void logError()
{ _errorCount++ ; }
const char* autoClassNamePostFix() const
{ return _autoClassPostFix.c_str() ; }
void setAutoClassNamePostFix(const char* pfix)
{ _autoClassPostFix = pfix ; }
std::map<std::string,IFace*>& hooks()
 Hooks for other tools
void clearError()
{ _errorCount = 0 ; }
Int_t errorCount()
{ return _errorCount ; }