AliPhysics  master (3d17d9d)
EstimateSingleTrackPIDsyst.C File Reference
#include <Riostream.h>
#include <TFile.h>
#include <TDirectoryFile.h>
#include <TCanvas.h>
#include <TH1F.h>
#include <TH2F.h>
#include <TF1.h>
#include <TStyle.h>
#include <TString.h>
#include <TList.h>
#include <TTree.h>
#include <TMath.h>
#include <TFractionFitter.h>
#include <TObjArray.h>
#include <TDatabasePDG.h>
#include <TGaxis.h>
#include <TLegend.h>
#include <TLatex.h>
#include <TProfile.h>
#include <vector>
#include <string>
#include <sstream>
#include <fstream>
#include "AliAnalysisTaskSEHFSystPID.h"
Include dependency graph for EstimateSingleTrackPIDsyst.C:

Go to the source code of this file.

Enumerations

enum  vars { kPt, kP }
 
enum  partPID {
  kElectron, kMuon, kPion, kKaon,
  kProton, kAll
}
 

Functions

int EstimateSingleTrackPIDsyst (int maxEntries=1e9, int var4proj=kP)
 
int GetHistoParticleIndex (short pdgcode)
 
int FindPtbin (float pt, const double binlims[], int nBins)
 
void ComputeEfficiency (double num, double den, double &eff, double &effunc)
 
void GetTOFFractionsFromData (int whichpart, int iBin, TH1F *hFractionMC[nPDGcodes-1], TH1F *hFractionData[nPDGcodes-1], TH1F *hNsigmaMC[nPDGcodes], TH1F *hNsigmaData, TFractionFitter *&fNsigmaFitter, vector< int > &templUsed)
 
double PDFnsigmaTPCtot (double *nsigma, double *pars)
 
void PlotQAhistos (TList *listMC, TList *listData)
 
void DivideCanvas (TCanvas *c, int nBins)
 
void SetStyle ()
 
void SetTH1Style (TH1F *histo, int markerstyle, int markercolor, float markersize, int linewidth, int linecolor, int fillcolor, float labelsize=-1, float titlesize=-1)
 

Variables

const int nPDGcodes = 6
 
const int pdgcodes [nPDGcodes] ={11,13,211,321,2212,-100}
 
const int pdgcolors [nPDGcodes] ={kOrange+7,kGray,kRed,kBlue,kGreen+2,kBlack}
 
const int pdgfillcolors [nPDGcodes] ={kOrange+7,kGray,kRed,kBlue,kGreen+2,kWhite}
 
const TString pdgnames [nPDGcodes] ={"Electron","Muon","Pion","Kaon","Proton","All"}
 
const double binlims [] = {0.3,0.5,0.75,1.,1.5,2.,3.,5.,10.}
 
const TString infileNameData = "/AnalysisResults_data.root"
 
const TString indirNameData = "PWGHF_D2H_SystNsigmaPID"
 
const TString inlistNameData = "coutputPIDhistos"
 
const TString infileNameMC = "AnalysisResults_MC.root"
 
const TString indirNameMC = "PWGHF_D2H_SystNsigmaPID"
 
const TString inlistNameMC = "coutputPIDhistos"
 
const TString outputdirName = "outputs/"
 
double absetamin = 0.
 
double absetamax = 1.
 

Enumeration Type Documentation

enum partPID
Enumerator
kElectron 
kMuon 
kPion 
kKaon 
kProton 
kAll 

Definition at line 43 of file EstimateSingleTrackPIDsyst.C.

enum vars
Enumerator
kPt 
kP 

Definition at line 42 of file EstimateSingleTrackPIDsyst.C.

Function Documentation

void ComputeEfficiency ( double  num,
double  den,
double &  eff,
double &  effunc 
)

Definition at line 1645 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

void DivideCanvas ( TCanvas *  c,
int  nBins 
)

Definition at line 1843 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

int EstimateSingleTrackPIDsyst ( int  maxEntries = 1e9,
int  var4proj = kP 
)

Definition at line 77 of file EstimateSingleTrackPIDsyst.C.

int FindPtbin ( float  pt,
const double  binlims[],
int  nBins 
)

Definition at line 1631 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

int GetHistoParticleIndex ( short  pdgcode)

Definition at line 1609 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

void GetTOFFractionsFromData ( int  whichpart,
int  iBin,
TH1F *  hFractionMC[nPDGcodes-1],
TH1F *  hFractionData[nPDGcodes-1],
TH1F *  hNsigmaMC[nPDGcodes],
TH1F *  hNsigmaData,
TFractionFitter *&  fNsigmaFitter,
vector< int > &  templUsed 
)

Definition at line 1661 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

double PDFnsigmaTPCtot ( double *  nsigma,
double *  pars 
)

Definition at line 1726 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

void PlotQAhistos ( TList listMC,
TList listData 
)

Definition at line 1739 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

void SetStyle ( )

Definition at line 1873 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

void SetTH1Style ( TH1F *  histo,
int  markerstyle,
int  markercolor,
float  markersize,
int  linewidth,
int  linecolor,
int  fillcolor,
float  labelsize = -1,
float  titlesize = -1 
)

Definition at line 1892 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

Variable Documentation

double absetamax = 1.

Definition at line 60 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

double absetamin = 0.

Definition at line 59 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

const double binlims[] = {0.3,0.5,0.75,1.,1.5,2.,3.,5.,10.}

Definition at line 50 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

const TString indirNameData = "PWGHF_D2H_SystNsigmaPID"

Definition at line 52 of file EstimateSingleTrackPIDsyst.C.

const TString indirNameMC = "PWGHF_D2H_SystNsigmaPID"

Definition at line 55 of file EstimateSingleTrackPIDsyst.C.

const TString infileNameData = "/AnalysisResults_data.root"

Definition at line 51 of file EstimateSingleTrackPIDsyst.C.

const TString infileNameMC = "AnalysisResults_MC.root"

Definition at line 54 of file EstimateSingleTrackPIDsyst.C.

const TString inlistNameData = "coutputPIDhistos"

Definition at line 53 of file EstimateSingleTrackPIDsyst.C.

const TString inlistNameMC = "coutputPIDhistos"

Definition at line 56 of file EstimateSingleTrackPIDsyst.C.

const int nPDGcodes = 6

Definition at line 44 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst(), and PDFnsigmaTPCtot().

const TString outputdirName = "outputs/"

Definition at line 57 of file EstimateSingleTrackPIDsyst.C.

const int pdgcodes[nPDGcodes] ={11,13,211,321,2212,-100}

Definition at line 45 of file EstimateSingleTrackPIDsyst.C.

const int pdgcolors[nPDGcodes] ={kOrange+7,kGray,kRed,kBlue,kGreen+2,kBlack}

Definition at line 46 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

const int pdgfillcolors[nPDGcodes] ={kOrange+7,kGray,kRed,kBlue,kGreen+2,kWhite}

Definition at line 47 of file EstimateSingleTrackPIDsyst.C.

Referenced by EstimateSingleTrackPIDsyst().

const TString pdgnames[nPDGcodes] ={"Electron","Muon","Pion","Kaon","Proton","All"}

Definition at line 48 of file EstimateSingleTrackPIDsyst.C.