attempt to move file to other directory
[u/mrichter/AliRoot.git] / PWG0 / AliCorrectionMatrix.h
CommitLineData
bf21645b 1#ifndef ALICORRECTIONMATRIX_H
2#define ALICORRECTIONMATRIX_H
3
4/* $Id$ */
5
6// ------------------------------------------------------
7//
8// Class to handle corrections.
9//
10// ------------------------------------------------------
11//
12// TODO:
13//
14// - add options in draw method
15//
16
17#include <TNamed.h>
18
19class TH1;
20
21class AliCorrectionMatrix : public TNamed
22{
1afae8ff 23protected: // do not create this baseclass
bf21645b 24 AliCorrectionMatrix();
25 AliCorrectionMatrix(const Char_t* name, const Char_t* title);
26 AliCorrectionMatrix(const AliCorrectionMatrix& c);
27 virtual ~AliCorrectionMatrix();
61385583 28 AliCorrectionMatrix& operator=(const AliCorrectionMatrix& corrMatrix);
bf21645b 29
1afae8ff 30public:
bf21645b 31 virtual void Copy(TObject& c) const;
32 virtual Long64_t Merge(TCollection* list);
33
34 TH1* GetGeneratedHistogram() { return fhGene; }
35 TH1* GetMeasuredHistogram() { return fhMeas; }
29771dc8 36 TH1* GetCorrectionHistogram() { return fhCorr; }
bf21645b 37
38 void SetGeneratedHistogram(TH1* agene) { fhGene = agene; }
39 void SetMeasuredHistogram(TH1* ameas) { fhMeas = ameas; }
29771dc8 40 void SetCorrectionHistogram(TH1* acorr) { fhCorr = acorr; }
bf21645b 41
42 void Divide();
29771dc8 43 void Multiply();
44 void SetCorrectionToUnity();
dd367a14 45 void Scale(Double_t factor);
bf21645b 46
2e88424e 47 void Add(AliCorrectionMatrix* aMatrixToAdd, Float_t c=1);
48
bf21645b 49 void SetAxisTitles(const Char_t* titleX="", const Char_t* titleY="", const Char_t* titleZ="");
50
29771dc8 51 virtual Bool_t LoadHistograms(const Char_t* dir = 0);
bf21645b 52 virtual void SaveHistograms();
53
29771dc8 54 virtual void DrawHistograms(const Char_t* canvasName = 0);
bf21645b 55
0ab29cfa 56 virtual void ReduceInformation();
57
ef2713c5 58 virtual void Reset(Option_t* option = "");
59
bf21645b 60protected:
61 TH1* fhMeas; // histogram of measured particles (or tracks)
62 TH1* fhGene; // histogram of generated particles
63
64 TH1* fhCorr; // correction histogram (ratio generated/measured)
65
66 ClassDef(AliCorrectionMatrix,1)
67};
68
69#endif
70