o) splitted analysis and correction of dneta
[u/mrichter/AliRoot.git] / PWG0 / dNdEta / CreatedNdEta.C
1 // this macro combines the correction and the analysis and draws them
2
3 void CreatedNdEta(Bool_t correct = kTRUE)
4 {
5   gSystem->Load("libPWG0base");
6
7   dNdEtaCorrection* dNdEtaCorrection = 0;
8   if (correct)
9   {
10     dNdEtaCorrection = new dNdEtaCorrection();
11     dNdEtaCorrection->LoadHistograms("correction_map.root","dndeta_correction");
12     dNdEtaCorrection->RemoveEdges(2, 0, 2);
13   }
14
15   fdNdEtaAnalysis = new dNdEtaAnalysis("dndeta", "dndeta");
16
17   TFile::Open("out.root");
18   fdNdEtaAnalysis->LoadHistograms();
19
20   fdNdEtaAnalysis->Finish(dNdEtaCorrection);
21
22   fdNdEtaAnalysis->DrawHistograms();
23 }
24
25