FairRoot/PandaRoot
|
#include <algorithm>
#include <map>
#include <utility>
#include <iostream>
#include "TFile.h"
#include "TTree.h"
#include "TLeaf.h"
#include "TString.h"
#include "TH1F.h"
#include "TCanvas.h"
#include "TROOT.h"
#include "TEventList.h"
#include "TDirectory.h"
#include "TLine.h"
#include "TLatex.h"
#include "TStyle.h"
#include "TObjArray.h"
#include "TPRegexp.h"
#include "TRegexp.h"
#include "TGraph.h"
Go to the source code of this file.
Macros | |
#define | MAX 1000 |
#define | BINS 100 |
#define | NCAN 3 |
Typedefs | |
typedef std::vector< pair < double, int > > | ValueMap |
typedef std::map< int, int > | CountMap |
Functions | |
int | gettype (TTree *t, TString varname) |
int | init (TTree *t) |
bool | mycompare (int i, int j) |
int | uid (int lev, int lrun, int lmode) |
int | countEvents (TTree *t, TEventList &el) |
void | makeMaps (TTree *t, TString varname, TEventList &els, TEventList &elb, ValueMap &sig, ValueMap &bg, int id) |
double | bestEffEvt (TTree *t, TString varname, TEventList &els, TEventList &elb, double &bestcut, double supr, int id) |
double | bestSuppressionEvt (TTree *t, TString varname, TEventList &els, TEventList &elb, double &bestcut, double eff, int id) |
double | bestCombiEvt (TTree *t, TString varname, TEventList &els, TEventList &elb, double &bestcut, double eff, int id) |
int | cutfinderx (TString fname, TString precut="", double supr=0.95, int evmult=10000, double norm=1.0, int n0s=-1) |
Variables | |
CountMap | evcnt |
CountMap | evcntrec [10] |
std::map< TString, TString > | mctvar |
Bool_t | isbt |
double | signi [MAX] |
int | idx [MAX] |
TString | vars [MAX] |
TString | cuts [MAX] |
double | cut [MAX] |
TGraph | grl [MAX] |
TGraph | grr [MAX] |
double | minh [MAX] |
double | maxh [MAX] |
double | N0_sig |
double | N0_bg |
double | Nsigev |
double | Nbgev |
bool | dstarmode |
Float_t | fbranch [MAX] |
Int_t | ibranch [MAX] |
Bool_t | bbranch [MAX] |
Int_t | ev |
Int_t | run |
Int_t | mode |
Int_t | rec |
Int_t | nbranch |
#define BINS 100 |
Definition at line 24 of file cutfinderx.C.
Referenced by bestCombiEvt(), and cutfinderx().
#define MAX 1000 |
Definition at line 23 of file cutfinderx.C.
#define NCAN 3 |
Definition at line 25 of file cutfinderx.C.
Definition at line 28 of file cutfinderx.C.
typedef std::vector<pair<double, int> > ValueMap |
Definition at line 27 of file cutfinderx.C.
double bestCombiEvt | ( | TTree * | t, |
TString | varname, | ||
TEventList & | els, | ||
TEventList & | elb, | ||
double & | bestcut, | ||
double | eff, | ||
int | id | ||
) |
Definition at line 325 of file cutfinderx.C.
References BINS, cuts, gettype(), grl, grr, i, makeMaps(), maxh, minh, Nb, Nbgev, Ns, Nsigev, printf(), and sqrt().
Referenced by cutfinderx().
double bestEffEvt | ( | TTree * | t, |
TString | varname, | ||
TEventList & | els, | ||
TEventList & | elb, | ||
double & | bestcut, | ||
double | supr, | ||
int | id | ||
) |
Definition at line 204 of file cutfinderx.C.
References cuts, gettype(), i, makeMaps(), Nbgev, and Nsigev.
Referenced by cutfinderx().
double bestSuppressionEvt | ( | TTree * | t, |
TString | varname, | ||
TEventList & | els, | ||
TEventList & | elb, | ||
double & | bestcut, | ||
double | eff, | ||
int | id | ||
) |
Definition at line 264 of file cutfinderx.C.
References cuts, gettype(), i, makeMaps(), Nbgev, and Nsigev.
Referenced by cutfinderx().
int countEvents | ( | TTree * | t, |
TEventList & | el | ||
) |
int cutfinderx | ( | TString | fname, |
TString | precut = "" , |
||
double | supr = 0.95 , |
||
int | evmult = 10000 , |
||
double | norm = 1.0 , |
||
int | n0s = -1 |
||
) |
Definition at line 397 of file cutfinderx.C.
References b, bestCombiEvt(), bestEffEvt(), bestSuppressionEvt(), BINS, c1, cnt, countEvents(), cut, cuts, dstarmode, elb, els, evcntrec, f, grl, grr, h1, h2, i, idx, init(), isbt, maxh, minh, mode, mycompare(), N0_bg, N0_sig, Nbgev, nbranch, nsig, Nsigev, printf(), s, signi, t, TString, and vars.
int gettype | ( | TTree * | t, |
TString | varname | ||
) |
Definition at line 56 of file cutfinderx.C.
References TString.
Referenced by bestCombiEvt(), bestEffEvt(), bestSuppressionEvt(), init(), and makeMaps().
int init | ( | TTree * | t | ) |
Definition at line 69 of file cutfinderx.C.
References bbranch, dstarmode, ev, fbranch, gettype(), i, ibranch, mode, nbranch, ok, rec, run, TString, v, and vars.
Referenced by cutfinderx().
void makeMaps | ( | TTree * | t, |
TString | varname, | ||
TEventList & | els, | ||
TEventList & | elb, | ||
ValueMap & | sig, | ||
ValueMap & | bg, | ||
int | id | ||
) |
Definition at line 159 of file cutfinderx.C.
References bbranch, ev, fbranch, gettype(), i, ibranch, max(), maxh, min(), minh, mode, run, and uid().
Referenced by bestCombiEvt(), bestEffEvt(), and bestSuppressionEvt().
bool mycompare | ( | int | i, |
int | j | ||
) |
int uid | ( | int | lev, |
int | lrun, | ||
int | lmode | ||
) |
Definition at line 128 of file cutfinderx.C.
Referenced by countEvents(), and makeMaps().
Definition at line 51 of file cutfinderx.C.
Referenced by init(), and makeMaps().
double cut[MAX] |
Definition at line 39 of file cutfinderx.C.
Referenced by cutfinderx().
Definition at line 38 of file cutfinderx.C.
Referenced by bestCombiEvt(), bestEffEvt(), bestSuppressionEvt(), and cutfinderx().
bool dstarmode |
Definition at line 47 of file cutfinderx.C.
Referenced by cutfinderx(), and init().
Int_t ev |
Definition at line 52 of file cutfinderx.C.
Referenced by countEvents(), init(), and makeMaps().
CountMap evcnt |
Definition at line 30 of file cutfinderx.C.
Referenced by countEvents().
CountMap evcntrec[10] |
Definition at line 30 of file cutfinderx.C.
Referenced by countEvents(), and cutfinderx().
Float_t fbranch[MAX] |
Definition at line 49 of file cutfinderx.C.
Referenced by init(), and makeMaps().
TGraph grl[MAX] |
Definition at line 40 of file cutfinderx.C.
Referenced by bestCombiEvt(), and cutfinderx().
TGraph grr[MAX] |
Definition at line 41 of file cutfinderx.C.
Referenced by bestCombiEvt(), and cutfinderx().
Int_t ibranch[MAX] |
Definition at line 50 of file cutfinderx.C.
Referenced by init(), and makeMaps().
int idx[MAX] |
Definition at line 36 of file cutfinderx.C.
Referenced by cutfinderx().
Bool_t isbt |
Definition at line 33 of file cutfinderx.C.
Referenced by cutfinderx().
double maxh[MAX] |
Definition at line 43 of file cutfinderx.C.
Referenced by bestCombiEvt(), cutfinderx(), and makeMaps().
Definition at line 31 of file cutfinderx.C.
double minh[MAX] |
Definition at line 43 of file cutfinderx.C.
Referenced by bestCombiEvt(), cutfinderx(), and makeMaps().
Int_t mode |
Definition at line 52 of file cutfinderx.C.
Referenced by countEvents(), cutfinderx(), init(), and makeMaps().
double N0_bg |
Definition at line 45 of file cutfinderx.C.
Referenced by cutfinderx().
double N0_sig |
Definition at line 45 of file cutfinderx.C.
Referenced by cutfinderx().
double Nbgev |
Definition at line 46 of file cutfinderx.C.
Referenced by bestCombiEvt(), bestEffEvt(), bestSuppressionEvt(), and cutfinderx().
Int_t nbranch |
Definition at line 52 of file cutfinderx.C.
Referenced by cutfinderx(), and init().
double Nsigev |
Definition at line 46 of file cutfinderx.C.
Referenced by bestCombiEvt(), bestEffEvt(), bestSuppressionEvt(), and cutfinderx().
Int_t rec |
Definition at line 52 of file cutfinderx.C.
Referenced by countEvents(), and init().
Int_t run |
Definition at line 52 of file cutfinderx.C.
Referenced by countEvents(), init(), and makeMaps().
double signi[MAX] |
Definition at line 35 of file cutfinderx.C.
Referenced by cutfinderx(), drawHistos(), and mycompare().
Definition at line 37 of file cutfinderx.C.
Referenced by cutfinderx(), and init().