]>
Commit | Line | Data |
---|---|---|
04fa961a | 1 | #ifndef ALIMONITORHISTO_H |
2 | #define ALIMONITORHISTO_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | ||
6 | /* $Id$ */ | |
7 | ||
8 | #include "AliMonitorPlot.h" | |
9 | #include <TH1.h> | |
10 | #include <TList.h> | |
11 | #include <TString.h> | |
12 | ||
13 | ||
14 | class AliMonitorHisto : public AliMonitorPlot { | |
15 | public: | |
16 | enum ENorm {kNormNone, kNormEvents, kNormEntries, kNormIntegral}; | |
17 | ||
18 | AliMonitorHisto(); | |
19 | AliMonitorHisto(const AliMonitorHisto& histo); | |
20 | AliMonitorHisto(TH1* histo, ENorm norm = kNormIntegral); | |
21 | virtual ~AliMonitorHisto(); | |
22 | ||
23 | static void SetNHistosMax(Int_t nHistosMax) {fgNHistosMax = nHistosMax;}; | |
24 | static Int_t GetNHistosMax() {return fgNHistosMax;}; | |
25 | ||
26 | virtual void SetReference(TH1* ref); | |
27 | virtual void SetReference(AliMonitorPlot* ref); | |
28 | ||
29 | void Fill(Axis_t x); | |
30 | void Fill(Axis_t x, Axis_t y); | |
31 | void Fill(Axis_t x, Axis_t y, Stat_t w); | |
32 | void ScaleErrorBy(Double_t factor); | |
33 | ||
34 | virtual void Update(); | |
35 | virtual void Update(TH1* histo); | |
36 | virtual void Add(AliMonitorPlot* plot); | |
37 | virtual void Reset(); | |
38 | virtual void ResetList(); | |
39 | ||
40 | protected: | |
41 | void Scale(Int_t nEvents); | |
42 | virtual Bool_t ComparePlot(); | |
43 | virtual Bool_t GetEvent(Int_t number = 1); | |
44 | virtual Bool_t GetSum(Int_t number); | |
45 | virtual Bool_t GetRun(); | |
46 | virtual void DrawPlot(); | |
47 | ||
48 | TH1* fHisto; //! the histogram that is currently filled with data | |
49 | TList fHistoList; // list of histograms of last fNHistos events | |
50 | Int_t fNHistos; // number of buffered histograms | |
51 | static Int_t fgNHistosMax; //! maximal number of buffered histograms | |
52 | TH1* fHistoRun; // sum of histograms for the current run | |
53 | ||
54 | TH1* fHistoDraw; //! the normalized histogram, used for comparison to a reference histogram | |
55 | TH1* fHistoRef; //! the reference histogram for comparison | |
56 | TH1* fHistoCompare; //! the result of the comparison to the reference histogram, only bins with large deviation are set | |
57 | ||
58 | ENorm fNorm; // type of normalization | |
59 | ||
60 | ClassDef(AliMonitorHisto, 2) // histogram for monitoring the quality of the recorded data | |
61 | }; | |
62 | ||
63 | ||
64 | #endif | |
65 | ||
66 | ||
67 | ||
68 | ||
69 | ||
70 | ||
71 | ||
72 | ||
73 |