changed saving of files
[u/mrichter/AliRoot.git] / PWG0 / dNdEta / dNdEtaAnalysis.h
CommitLineData
dc740de4 1/* $Id$ */
2
539b6cb4 3#ifndef DNDETANALYSIS_H
4#define DNDETANALYSIS_H
5
75ec0f41 6// ------------------------------------------------------
7//
8// Class for dn/deta analysis
9//
10// ------------------------------------------------------
11//
12// TODO:
13// - more documentation
14// - add debug statements
15// - add more histograms
16// - add functionality to set the bin sizes
17// - figure out correct way to treat the errors
18// - add functionality to make dn/deta for different mult classes?
4dd2ad81 19// - implement destructor
75ec0f41 20
7029240a 21#include <TNamed.h>
75ec0f41 22
ceb5d1b5 23class TH2F;
24class TH1D;
7029240a 25class TCollection;
75ec0f41 26
7029240a 27class dNdEtaAnalysis : public TNamed
ceb5d1b5 28{
75ec0f41 29public:
7029240a 30 enum { kVertexBinning = 1 };
31
32 dNdEtaAnalysis(Char_t* name, Char_t* title);
75ec0f41 33
34 void FillTrack(Float_t vtx, Float_t eta, Float_t weight);
35 void FillEvent(Float_t vtx);
ceb5d1b5 36
75ec0f41 37 void Finish();
ceb5d1b5 38
39 void DrawHistograms();
75ec0f41 40 void SaveHistograms();
ceb5d1b5 41
7029240a 42 virtual Long64_t Merge(TCollection* list);
43
ceb5d1b5 44 TH2F* GetEtaVsVtxHistogram() { return hEtaVsVtx; }
45 TH2F* GetEtaVsVtxUncorrectedHistogram() { return hEtaVsVtxUncorrected; }
46 TH1D* GetVtxHistogram() { return hVtx; }
7029240a 47 TH1D* GetdNdEtaHistogram(Int_t i = 0) { return hdNdEta[i]; }
ceb5d1b5 48
49protected:
ceb5d1b5 50 TH2F* hEtaVsVtx;
51 TH2F* hEtaVsVtxUncorrected;
52 TH1D* hVtx;
7029240a 53 TH1D* hdNdEta[kVertexBinning];
ceb5d1b5 54
75ec0f41 55 ClassDef(dNdEtaAnalysis,0)
56};
57
539b6cb4 58#endif