source: trunk/MagicSoft/Mars/mhist/MHOnSubtraction.h@ 4188

Last change on this file since 4188 was 2522, checked in by tbretz, 21 years ago
*** empty log message ***
File size: 2.0 KB
Line 
1#ifndef MARS_MHOnSubtraction
2#define MARS_MHOnSubtraction
3
4#ifndef MARS_MH
5#include "MH.h"
6#endif
7
8class TH1D;
9class TH3D;
10class TPad;
11class TGraph;
12class TLegend;
13class TPaveLabel;
14
15class MHArray;
16
17class MHOnSubtraction : public MH
18{
19private:
20 TString fHistogramType;
21 TH1D* fChiSquareHisto;
22 TH1D* fSignificanceHisto;
23 TH1D* fSummedAlphaPlots;
24 MHArray *fThetaHistoArray;
25 TLegend *fThetaLegend;
26 Double_t fMaxSignif;
27 Double_t fMaxRedChiSq;
28 Double_t fSlope; // slope for exponential fit
29 Int_t fThetaBin;
30 Int_t fSigniPlotIndex;
31 Int_t fSigniPlotColor;
32
33 Double_t fSignificance;
34
35 Bool_t CalcAET(TH3D *histon, MParList *parlist, const Bool_t Draw);
36
37 Bool_t FitHistogram(TH1 &alphaHisto, Double_t &sigLiMa,
38 Double_t &lowerBin, Double_t &upperBin,
39 Float_t signalRegionFactor = 3, const Bool_t draw = kFALSE,
40 TString funcName = "");
41
42 Bool_t ExtractSignal(TH1 &alphaHisto, Double_t &sigLiMa,
43 Double_t &lowerBin, Double_t &upperBin,
44 Double_t &gammaSignal, Double_t &errorGammaSignal,
45 Double_t &off, Double_t &errorOff,
46 Float_t signalRegionFactor = 3, const Bool_t draw = kFALSE,
47 TString funcName = "", TPad *drawPad = 0, Int_t drawBase = 0);
48
49
50
51public:
52 MHOnSubtraction(const char *name=NULL, const char *title=NULL);
53 ~MHOnSubtraction();
54
55 Double_t CalcSignificance(Double_t nOn, Double_t nOff, Double_t theta);
56 Double_t GetSignificance() { return fSignificance; };
57
58 void SetExpoSlope(Double_t slope) { fSlope = slope; }
59
60 Bool_t Calc(MParList *parlist, const Bool_t Draw);
61
62 Bool_t Calc(TH3 *histon, MParList *parlist, const Bool_t Draw);
63 Bool_t TH2Calc(TH2 *aeHisto, MParList *parlist, const Bool_t Draw,
64 TPad *drawPad = 0, Int_t drawBase = 0);
65 Bool_t Calc(TH1 *histon, MParList *parlist, const Bool_t Draw,
66 Float_t signalRegion = 0);
67
68 void Draw(Option_t *option="");
69 TObject *DrawClone(Option_t *option="") const;
70
71 ClassDef(MHOnSubtraction, 1) //Extracts gamma signals from pure ON-data
72};
73
74#endif
75
Note: See TracBrowser for help on using the repository browser.