test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
StatisticalPlot.h
Go to the documentation of this file.
1 
12 #ifndef __StatisticalPlot__
13 #define __StatisticalPlot__
14 
15 
16 #include "TNamed.h"
17 #include "TCanvas.h"
18 
19 #include "TFile.h"
20 
21 class StatisticalPlot : public TNamed {
22 
23  public:
24 
26  StatisticalPlot(const char* name,const char* title,bool verbosity=true);
27 
30 
32  void setVerbosity(bool verbosity);
33 
35  bool is_verbose();
36 
38  TCanvas* getCanvas(){return m_canvas;}
39 
41  void setCanvas(TCanvas* new_canvas){m_canvas=new_canvas;}
42 
44  void dumpToImage (const char* filename){m_canvas->Print(filename);}
45 
47  virtual void draw (const char* options="") = 0;
48 
50  virtual void print (const char* options="") = 0;
51 
53  virtual void dumpToFile (const char* RootFileName, const char* options="") = 0;
54 
55  private:
56 
58  bool m_verbose;
59 
61  TCanvas* m_canvas;
62 
63 //For Cint
64 #if (defined (STANDALONE) or defined (__CINT__) )
65 ClassDef(StatisticalPlot,1)
66 #endif
67  };
68 
69 #endif
70 // Automatically converted from the standalone version Wed Apr 15 11:36:34 2009
bool m_verbose
Verbosity flag.
virtual void print(const char *options="")=0
Print the relevant information.
virtual void draw(const char *options="")=0
Draw on canvas.
void setCanvas(TCanvas *new_canvas)
Set the canvas.
TCanvas * m_canvas
Canvas.
StatisticalPlot: the base class for the statistical plots.
~StatisticalPlot()
Destructor.
void dumpToImage(const char *filename)
Write an image on disk.
tuple filename
Definition: lut2db_cfg.py:20
TCanvas * getCanvas()
Get the canvas.
StatisticalPlot(const char *name, const char *title, bool verbosity=true)
Constructor.
bool is_verbose()
get the verbosity
virtual void dumpToFile(const char *RootFileName, const char *options="")=0
All the objects are written to rootfile.
void setVerbosity(bool verbosity)
Set the verbosity.