GRSISort "v4.0.0.5"
An extension of the ROOT analysis Framework
Loading...
Searching...
No Matches
GH2D.h
Go to the documentation of this file.
1#ifndef GH2D__H
2#define GH2D__H
3
4#include <cstdio>
5#include <map>
6
7#include <TNamed.h>
8#include <TH2.h>
9#include <TList.h>
10#include <TVirtualPad.h>
11#include <TFrame.h>
12
13#include <TCutG.h>
14#include <GH2Base.h>
15
16class GH1D;
17
18class GH2D : public TH2D, public GH2Base {
19
20public:
21 GH2D() = default;
22 GH2D(const char* name, const char* title, Int_t nbinsx, const Double_t* xbins, Int_t nbinsy, const Double_t* ybins);
23 GH2D(const char* name, const char* title, Int_t nbinsx, const Float_t* xbins, Int_t nbinsy, const Float_t* ybins);
24 GH2D(const char* name, const char* title, Int_t nbinsx, const Double_t* xbins, Int_t nbinsy, Double_t ylow, Double_t yup);
25 GH2D(const char* name, const char* title, Int_t nbinsx, Double_t xlow, Double_t xup, Int_t nbinsy, Double_t* ybins);
26 GH2D(const char* name, const char* title, Int_t nbinsx, Double_t xlow, Double_t xup, Int_t nbinsy, Double_t ylow, Double_t yup);
27 explicit GH2D(const TObject&);
28 GH2D(const GH2D&) = default;
29 GH2D(GH2D&&) noexcept = default;
30 GH2D& operator=(const GH2D&) = default;
31 GH2D& operator=(GH2D&&) noexcept = default;
32 ~GH2D();
33
34 void Draw(Option_t* opt = "") override;
35 virtual void Draw(TCutG*);
36 TH1* DrawCopy(Option_t* opt = "", const char* name_postfix = "_copy") const override;
37 TH1* DrawNormalized(Option_t* opt = "", Double_t norm = 1) const override;
38
39 void Clear(Option_t* opt = "") override;
40 void Print(Option_t* opt = "") const override;
41 void Copy(TObject&) const override;
42 TObject* Clone(const char* newname = "") const override;
43
44 GH1D* ProjectionX(const char* name = "_px", int firstbin = 0, int lastbin = -1, Option_t* option = ""); // *MENU*
45
46 GH1D* ProjectionY(const char* name = "_py", int firstbin = 0, int lastbin = -1, Option_t* option = ""); // *MENU*
47
48 TH2* GetTH2() override { return this; }
49
50private:
51 /// /cond CLASSIMP
52 ClassDefOverride(GH2D, 1) // NOLINT(readability-else-after-return)
53 /// /endcond
54};
55
56#endif
Definition GH1D.h:17
Definition GH2D.h:18
GH1D * ProjectionX(const char *name="_px", int firstbin=0, int lastbin=-1, Option_t *option="")
Definition GH2D.cxx:114
void Print(Option_t *opt="") const override
Definition GH2D.cxx:68
GH2D(const GH2D &)=default
GH2D(GH2D &&) noexcept=default
TH1 * DrawNormalized(Option_t *opt="", Double_t norm=1) const override
Definition GH2D.cxx:104
void Draw(Option_t *opt="") override
Definition GH2D.cxx:72
TH1 * DrawCopy(Option_t *opt="", const char *name_postfix="_copy") const override
Definition GH2D.cxx:94
void Clear(Option_t *opt="") override
Definition GH2D.cxx:59
GH2D()=default
void Copy(TObject &) const override
Definition GH2D.cxx:43
TH2 * GetTH2() override
Definition GH2D.h:48
TObject * Clone(const char *newname="") const override
Definition GH2D.cxx:50
GH1D * ProjectionY(const char *name="_py", int firstbin=0, int lastbin=-1, Option_t *option="")
Definition GH2D.cxx:119