Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
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:
37  TGraph2DErrors();
38  TGraph2DErrors(Int_t n);
39  TGraph2DErrors(Int_t n, Double_t *x, Double_t *y, Double_t *z,
40  Double_t *ex=0, Double_t *ey=0, Double_t *ez=0, Option_t *option="");
41  TGraph2DErrors(const TGraph2DErrors&);
42  TGraph2DErrors& operator=(const TGraph2DErrors&);
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  virtual void Set(Int_t n);
58  virtual void SetPoint(Int_t i, Double_t x, Double_t y, Double_t z);
59  virtual void SetPointError(Int_t i, Double_t ex, Double_t ey, Double_t ez);
60 
61  ClassDef(TGraph2DErrors,1) //A 2D graph with error bars
62 };
63 
64 #endif
65 
66