Logo ROOT  
Reference Guide
TGraph2DErrors.h
Go to the documentation of this file.
1 // @(#)root/hist:$Id: TGraph2DErrors.h,v 1.00
2 // Author: Olivier Couet 26/11/2003
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef ROOT_TGraph2DErrors
13 #define ROOT_TGraph2DErrors
14 
15 
16 //////////////////////////////////////////////////////////////////////////
17 // //
18 // TGraph2DErrors //
19 // //
20 // a 2D Graph with error bars //
21 // //
22 //////////////////////////////////////////////////////////////////////////
23 
24 #include "TGraph2D.h"
25 
26 class TGraph2DErrors : public TGraph2D {
27 
28 private:
29 
30 
31 protected:
32  Double_t *fEX; ///<[fNpoints] array of X errors
33  Double_t *fEY; ///<[fNpoints] array of Y errors
34  Double_t *fEZ; ///<[fNpoints] array of Z errors
35 
36 public:
40  Double_t *ex=0, Double_t *ey=0, Double_t *ez=0, Option_t *option="");
43  virtual ~TGraph2DErrors();
44  Double_t GetErrorX(Int_t bin) const;
45  Double_t GetErrorY(Int_t bin) const;
46  Double_t GetErrorZ(Int_t bin) const;
47  Double_t *GetEX() const {return fEX;}
48  Double_t *GetEY() const {return fEY;}
49  Double_t *GetEZ() const {return fEZ;}
50  Double_t GetXmaxE() const;
51  Double_t GetXminE() const;
52  Double_t GetYmaxE() const;
53  Double_t GetYminE() const;
54  Double_t GetZmaxE() const;
55  Double_t GetZminE() const;
56  virtual void Print(Option_t *chopt="") const;
57  Int_t RemovePoint(Int_t ipoint); // *MENU*
58  virtual void Set(Int_t n);
59  virtual void SetPoint(Int_t i, Double_t x, Double_t y, Double_t z);
60  virtual void SetPointError(Int_t i, Double_t ex, Double_t ey, Double_t ez);
61 
62  ClassDef(TGraph2DErrors,1) //A 2D graph with error bars
63 };
64 
65 #endif
66 
67 
ex
Double_t ex[n]
Definition: legend1.C:17
TGraph2DErrors::SetPointError
virtual void SetPointError(Int_t i, Double_t ex, Double_t ey, Double_t ez)
Set ex, ey and ez values for point number i.
Definition: TGraph2DErrors.cxx:416
n
const Int_t n
Definition: legend1.C:16
TGraph2DErrors::RemovePoint
Int_t RemovePoint(Int_t ipoint)
Deletes point number ipoint.
Definition: TGraph2DErrors.cxx:326
TGraph2DErrors::GetErrorZ
Double_t GetErrorZ(Int_t bin) const
This function is called by Graph2DFitChisquare.
Definition: TGraph2DErrors.cxx:226
TGraph2D.h
TGraph2DErrors::Print
virtual void Print(Option_t *chopt="") const
Print 2D graph and errors values.
Definition: TGraph2DErrors.cxx:303
TGraph2DErrors::Set
virtual void Set(Int_t n)
Set number of points in the 2D graph.
Definition: TGraph2DErrors.cxx:315
TGraph2DErrors::fEZ
Double_t * fEZ
[fNpoints] array of Z errors
Definition: TGraph2DErrors.h:40
TGraph2DErrors::fEX
Double_t * fEX
[fNpoints] array of X errors
Definition: TGraph2DErrors.h:38
TGraph2DErrors::~TGraph2DErrors
virtual ~TGraph2DErrors()
TGraph2DErrors destructor.
Definition: TGraph2DErrors.cxx:143
TGraph2DErrors::fEY
Double_t * fEY
[fNpoints] array of Y errors
Definition: TGraph2DErrors.h:39
x
Double_t x[n]
Definition: legend1.C:17
TGraph2DErrors::GetYmaxE
Double_t GetYmaxE() const
Returns the Y maximum with errors.
Definition: TGraph2DErrors.cxx:259
TGraph2DErrors
Definition: TGraph2DErrors.h:26
TGraph2DErrors::GetZmaxE
Double_t GetZmaxE() const
Returns the Z maximum with errors.
Definition: TGraph2DErrors.cxx:281
TGraph2DErrors::GetXmaxE
Double_t GetXmaxE() const
Returns the X maximum with errors.
Definition: TGraph2DErrors.cxx:237
Option_t
const typedef char Option_t
Definition: RtypesCore.h:66
TGraph2D
Definition: TGraph2D.h:41
TGraph2DErrors::GetEY
Double_t * GetEY() const
Definition: TGraph2DErrors.h:54
TGraph2DErrors::GetYminE
Double_t GetYminE() const
Returns the Y minimum with errors.
Definition: TGraph2DErrors.cxx:270
TGraph2DErrors::GetZminE
Double_t GetZminE() const
Returns the Z minimum with errors.
Definition: TGraph2DErrors.cxx:292
y
Double_t y[n]
Definition: legend1.C:17
ey
Double_t ey[n]
Definition: legend1.C:17
TGraph2DErrors::GetXminE
Double_t GetXminE() const
Returns the X minimum with errors.
Definition: TGraph2DErrors.cxx:248
TGraph2DErrors::TGraph2DErrors
TGraph2DErrors()
TGraph2DErrors default constructor.
Definition: TGraph2DErrors.cxx:81
TGraph2DErrors::GetErrorX
Double_t GetErrorX(Int_t bin) const
This function is called by Graph2DFitChisquare.
Definition: TGraph2DErrors.cxx:202
Double_t
double Double_t
Definition: RtypesCore.h:59
ClassDef
#define ClassDef(name, id)
Definition: Rtypes.h:325
TGraph2DErrors::GetErrorY
Double_t GetErrorY(Int_t bin) const
This function is called by Graph2DFitChisquare.
Definition: TGraph2DErrors.cxx:214
TGraph2DErrors::SetPoint
virtual void SetPoint(Int_t i, Double_t x, Double_t y, Double_t z)
Set x, y and z values for point number i.
Definition: TGraph2DErrors.cxx:374
TGraph2DErrors::GetEX
Double_t * GetEX() const
Definition: TGraph2DErrors.h:53
TGraph2DErrors::operator=
TGraph2DErrors & operator=(const TGraph2DErrors &)
Assignment operator Copy everything except list of functions.
Definition: TGraph2DErrors.cxx:173
int
TGraph2DErrors::GetEZ
Double_t * GetEZ() const
Definition: TGraph2DErrors.h:55