Logo ROOT  
Reference Guide
RooEfficiency.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * Project: RooFit *
3  * Package: RooFitCore *
4  * File: $Id: RooEfficiency.h,v 1.6 2007/05/11 10:14:56 verkerke Exp $
5  * Authors: *
6  * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu *
7  * DK, David Kirkby, UC Irvine, dkirkby@uci.edu *
8  * *
9  * Copyright (c) 2000-2005, Regents of the University of California *
10  * and Stanford University. All rights reserved. *
11  * *
12  * Redistribution and use in source and binary forms, *
13  * with or without modification, are permitted according to the terms *
14  * listed in LICENSE (http://roofit.sourceforge.net/license.txt) *
15  *****************************************************************************/
16 #ifndef ROO_EFFICIENCY
17 #define ROO_EFFICIENCY
18 
19 #include "RooAbsPdf.h"
20 #include "RooCategoryProxy.h"
21 #include "RooRealProxy.h"
22 #include "TString.h"
23 
24 class RooArgList ;
25 
26 
27 class RooEfficiency : public RooAbsPdf {
28 public:
29  // Constructors, assignment etc
30  inline RooEfficiency() {
31  // Default constructor
32  }
33  RooEfficiency(const char *name, const char *title, const RooAbsReal& effFunc, const RooAbsCategory& cat, const char* sigCatName);
34  RooEfficiency(const RooEfficiency& other, const char* name=0);
35  virtual TObject* clone(const char* newname) const { return new RooEfficiency(*this,newname); }
36  virtual ~RooEfficiency();
37 
38  Int_t getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, const char* rangeName=0) const ;
39  Double_t analyticalIntegral(Int_t code, const char* rangeName=0) const ;
40 
41 protected:
42 
43  // Function evaluation
44  virtual Double_t evaluate() const ;
45  RooCategoryProxy _cat ; // Accept/reject categort
46  RooRealProxy _effFunc ; // Efficiency modeling function
47  TString _sigCatName ; // Name of accept state of accept/reject category
48 
49  ClassDef(RooEfficiency,1) // Generic PDF defined by string expression and list of variables
50 };
51 
52 #endif
RooEfficiency::_sigCatName
TString _sigCatName
Definition: RooEfficiency.h:47
RooArgList
RooArgList is a container object that can hold multiple RooAbsArg objects.
Definition: RooArgList.h:21
RooEfficiency::analyticalIntegral
Double_t analyticalIntegral(Int_t code, const char *rangeName=0) const
Implements the actual analytical integral(s) advertised by getAnalyticalIntegral.
Definition: RooEfficiency.cxx:120
RooAbsReal
RooAbsReal is the common abstract base class for objects that represent a real value and implements f...
Definition: RooAbsReal.h:61
TString
Basic string class.
Definition: TString.h:136
RooEfficiency::_effFunc
RooRealProxy _effFunc
Definition: RooEfficiency.h:46
TString.h
RooEfficiency::~RooEfficiency
virtual ~RooEfficiency()
Destructor.
Definition: RooEfficiency.cxx:76
RooEfficiency::clone
virtual TObject * clone(const char *newname) const
Definition: RooEfficiency.h:35
RooAbsCategory
RooAbsCategory is the base class for objects that represent a discrete value with a finite number of ...
Definition: RooAbsCategory.h:37
RooEfficiency::RooEfficiency
RooEfficiency()
Definition: RooEfficiency.h:30
RooAbsPdf.h
RooRealProxy.h
RooCategoryProxy.h
RooEfficiency::getAnalyticalIntegral
Int_t getAnalyticalIntegral(RooArgSet &allVars, RooArgSet &analVars, const char *rangeName=0) const
Interface function getAnalyticalIntergral advertises the analytical integrals that are supported.
Definition: RooEfficiency.cxx:110
RooEfficiency::evaluate
virtual Double_t evaluate() const
Calculate the raw value of this p.d.f which is the effFunc value if cat==1 and it is (1-effFunc) if c...
Definition: RooEfficiency.cxx:86
RooTemplateProxy< RooAbsCategory >
Double_t
double Double_t
Definition: RtypesCore.h:59
TObject
Mother of all ROOT objects.
Definition: TObject.h:37
ClassDef
#define ClassDef(name, id)
Definition: Rtypes.h:325
name
char name[80]
Definition: TGX11.cxx:110
RooEfficiency
RooEfficiency is a PDF helper class to fit efficiencies parameterized by a supplied function F.
Definition: RooEfficiency.h:27
RooAbsPdf
Definition: RooAbsPdf.h:43
RooEfficiency::_cat
RooCategoryProxy _cat
Definition: RooEfficiency.h:45
RooArgSet
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Definition: RooArgSet.h:29
int