]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGCF/FLOW/Documentation/examples/plotGlauberMCexample.C
Moving/split PWG2/FLOW to PWGCF/FLOW, PWG/FLOW/Base, PWG/FLOW/Tasks, PWG/Glauber
[u/mrichter/AliRoot.git] / PWGCF / FLOW / Documentation / examples / plotGlauberMCexample.C
1 {
2   // open file
3   TFile* f = new TFile("GlauberMC_PbPb_ntuple.root");
4   TTree* t = (TTree*)gDirectory->Get("nt_Pb_Pb"); // get the tree
5
6   gStyle->SetCanvasColor(0);
7   gStyle->SetFrameBorderMode(0);
8   gStyle->SetStatBorderSize(1);
9   gStyle->SetFrameFillColor(0);
10   gStyle->SetTitleFillColor(0);
11   gStyle->SetPalette(1);
12
13   TCanvas* c = new TCanvas("GlauberMC","GlauberMC");
14   c->Divide(2,3);
15   c->cd(1);
16   // plot number of collisions
17   t->Draw("Ncoll:B","","prof");
18   c->cd(2);
19   // plot number of wounded nucleons
20   t->Draw("Npart:B","","prof");
21   c->cd(3);
22   t->Draw("VarE:Npart","","prof");
23   c->cd(4);
24   t->Draw("VarEPart:Npart","","prof");
25   c->cd(5);
26   t->Draw("dNdEta:B");
27   c->cd(6);
28   t->Draw("dNdEtaGBW:B");
29
30   c->cd(0);
31
32   c->Update();
33 }