19 c->SetRightMargin(.05);
20 c->SetBottomMargin(.1);
47 gROOT->Macro(
"$ALICE_PHYSICS/PWGLF/FORWARD/analysis2/scripts/LoadLibs.C");
49 TFile*
file = TFile::Open(fname,
"READ");
51 Error(
"DrawCorrVtxBias",
"Failed to open %s", fname);
55 pname.ReplaceAll(
".root",
".pdf");
63 Error(
"DrawCorrVtxBias",
"Object '%s' not found in %s", objName, fname);
69 TCanvas* c =
new TCanvas(
"c",
"c", 800 / TMath::Sqrt(2), 800);
73 c->Print(Form(
"%s[", pname.Data()));
75 gStyle->SetOptStat(0);
76 gStyle->SetTitleColor(0);
77 gStyle->SetTitleStyle(0);
78 gStyle->SetTitleBorderSize(0);
79 gStyle->SetTitleX(.1);
81 gStyle->SetTitleW(.8);
82 gStyle->SetTitleH(.09);
83 gStyle->SetFrameFillColor(kWhite);
84 gStyle->SetFrameBorderSize(1);
85 gStyle->SetFrameBorderMode(1);
86 gStyle->SetPalette(1);
91 TLatex* ll =
new TLatex(.5,.8, fname);
93 ll->SetTextSize(0.03);
97 TLatex* l =
new TLatex(.5,.8, fname);
102 l->DrawLatex(0.2, 0.70,
"Vertex Bias Corrections");
104 l->DrawLatex(0.5, 0.60,
"c_{v}(#eta,#phi)=#frac{1/N_{t}}{1/N_{v}}" 105 "#sum_{i}^{N_{tv}}N_{ch,i}(#eta,#phi) / " 106 "#sum_{i}^{N_{v}}N_{ch,i}(#eta,#phi)");
108 l->DrawLatex(0.2, 0.50,
"N_{t}: Number of events w/triggers");
109 l->DrawLatex(0.2, 0.45,
"N_{v}: Number of events w/vertex");
110 l->DrawLatex(0.2, 0.40,
"N_{tv}: Number of events w/trigger and vertex");
111 l->DrawLatex(0.2, 0.35,
"N_{ch,i}(#eta,#phi): Number of charged, " 112 "particles in (#eta,#phi) bin");
113 l->DrawLatex(0.2, 0.30,
"All quantities determined in MC");
115 c->Print(pname.Data(),
"Title:Title page");
122 Int_t nVtx = vtxAxis.GetNbins();
126 Char_t r = (q == 0 ?
'I' :
'O');
129 c->Divide(2, (nVtx+1)/2);
130 for (
UShort_t v=1; v <= nVtx; v++) {
131 TVirtualPad* p = c->cd(v);
136 Warning(
"DrawCorrVtxBias",
"No correction for r=%c, v=%d", r, v);
141 c->Print(pname.Data(), Form(
"Title:FMDX%c", r));
146 c->Print(Form(
"%s]", pname.Data()));
TH2D * GetCorrection(Char_t r, Double_t v) const
void DrawCorrVtxBias(const char *fname, const char *option="colz")
const char * GetObjectName(Int_t what) const
const TAxis & GetVertexAxis() const
void ClearCanvas(TCanvas *c)
TFile * file
TList with histograms for a given trigger.
static AliForwardCorrectionManager & Instance()