bug fixed that was considered also under/overflow bins in vertex axis
[u/mrichter/AliRoot.git] / PWG0 / AliCorrection.h
CommitLineData
29771dc8 1#ifndef ALICORRECTION_H
2#define ALICORRECTION_H
3
4/* $Id$ */
5
6// ------------------------------------------------------
7//
8// This class is used to store the correction for one effect.
9//
10// Most effects have to be correction on track and event level, this class combines
11// two correction matrices. One of the type AliCorrectionMatrix2D and one of
12// the type AliCorrectionMatrix3D
13//
14// ------------------------------------------------------
15
16#include <TNamed.h>
770a1f1d 17#include "AliPWG0Helper.h"
29771dc8 18
19class AliCorrectionMatrix2D;
20class AliCorrectionMatrix3D;
21
22class AliCorrection : public TNamed
23{
24public:
25 AliCorrection();
770a1f1d 26 AliCorrection(const Char_t* name, const Char_t* title, AliPWG0Helper::AnalysisMode analysisMode = AliPWG0Helper::kTPC);
29771dc8 27 AliCorrection(const AliCorrection& c);
28
29 virtual ~AliCorrection();
30 AliCorrection& operator=(const AliCorrection& corr);
31 virtual void Copy(TObject& c) const;
32
33 virtual Long64_t Merge(TCollection* list);
34
35 AliCorrectionMatrix2D* GetEventCorrection() { return fEventCorr; }
36 AliCorrectionMatrix3D* GetTrackCorrection() { return fTrackCorr; }
37
38 void SetEventCorrection(AliCorrectionMatrix2D* corr) { fEventCorr = corr; }
39 void SetTrackCorrection(AliCorrectionMatrix3D* corr) { fTrackCorr = corr; }
40
41 void Divide();
42 void Multiply();
43 void SetCorrectionToUnity();
dd367a14 44 void Scale(Double_t factor);
29771dc8 45
2e88424e 46 void Add(AliCorrection* aCorrectionToAdd, Float_t c=1);
47
29771dc8 48 virtual Bool_t LoadHistograms(const Char_t* dir = 0);
49 virtual void SaveHistograms();
50 virtual void DrawHistograms(const Char_t* name = 0);
dd367a14 51 virtual void DrawOverview(const char* canvasName = 0);
29771dc8 52
53 virtual void ReduceInformation();
54
55 virtual void Reset(Option_t* option = "");
dd367a14 56 void PrintInfo(Float_t ptCut);
29771dc8 57
58protected:
59 AliCorrectionMatrix2D* fEventCorr; // correction on event level
60 AliCorrectionMatrix3D* fTrackCorr; // correction on track level
61
62 ClassDef(AliCorrection,1)
63};
64
65#endif
66