updating makefile to build all PWG0libs
[u/mrichter/AliRoot.git] / PWG0 / dNdEta / dNdEtaAnalysis.h
... / ...
CommitLineData
1/* $Id$ */
2
3#ifndef DNDETANALYSIS_H
4#define DNDETANALYSIS_H
5
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?
19// - implement destructor
20
21#include <TNamed.h>
22
23class TH3F;
24class TH1D;
25class TCollection;
26class AlidNdEtaCorrection;
27
28class dNdEtaAnalysis : public TNamed
29{
30public:
31 enum { kVertexBinning = 1+4 }; // the first is for the whole vertex range, the others divide the vertex range
32
33 dNdEtaAnalysis(Char_t* name, Char_t* title);
34 virtual ~dNdEtaAnalysis();
35
36 dNdEtaAnalysis(const dNdEtaAnalysis &c);
37 dNdEtaAnalysis &operator=(const dNdEtaAnalysis &c);
38 virtual void Copy(TObject &c) const;
39
40 void FillTrack(Float_t vtx, Float_t eta, Float_t pt, Float_t weight);
41 void FillEvent(Float_t vtx, Float_t weight);
42
43 void Finish(AlidNdEtaCorrection* correction, Float_t ptCut);
44
45 void DrawHistograms();
46 void LoadHistograms();
47 void SaveHistograms();
48
49 virtual Long64_t Merge(TCollection* list);
50
51 TH3F* GetHistogram() { return fData; }
52 TH3F* GetUncorrectedHistogram() { return fDataUncorrected; }
53 TH1D* GetVtxHistogram() { return fVtx; }
54 TH1D* GetdNdEtaHistogram(Int_t i = 0) { return fdNdEta[i]; }
55
56protected:
57 TH3F* fData; // histogram Eta vs vtx (track count)
58 TH3F* fDataUncorrected; // uncorrected histograms Eta vs vtx (track count)
59
60 Float_t fNEvents; // number of events (float because corrected by weight)
61
62 TH1D* fVtx; // vtx histogram (event count)
63 TH1D* fdNdEta[kVertexBinning];// dndeta results for different vertex bins (0 = full range)
64
65 ClassDef(dNdEtaAnalysis, 0)
66};
67
68#endif