ATLAS Offline Software
ShapeDrawer.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
11 #ifndef LArSamples_ShapeDrawer_H
12 #define LArSamples_ShapeDrawer_H
13 
14 #include <vector>
16 
17 class TGraphErrors;
18 class TLegend;
19 
20 namespace LArSamples {
21 
23 
24  class AbsShape;
25 
27 
28  public:
29 
31  ShapeDrawer(int pars) : m_pars(pars) { }
32 
33  TGraphErrors* graph(const AbsShape& shape, const char* title = "") const;
34 
35  TGraphErrors* draw(const AbsShape* shape, const char* title = "", bool drawAxes = true, const char* gopt = "P") const;
36 
37  bool draw(const char* title, const std::vector<const AbsShape*>& shapes,
38  const AbsShape* reference = 0, const AbsShape* refSamples = 0) const;
39  bool draw(const char* title, const AbsShape* shape, const AbsShape* reference = 0, const AbsShape* refSamples = 0) const;
40 
41  bool drawAndDelete(const char* title, const std::vector<const AbsShape*>& shapes,
42  const AbsShape* reference = 0, const AbsShape* refSamples = 0) const;
43  bool drawAndDelete(const char* title, const AbsShape* shape, const AbsShape* reference = 0, const AbsShape* refSamples = 0) const;
44 
45  bool colorize(TGraphErrors* data, unsigned int index) const;
46 
47  bool yAxisLimits(const std::vector<const AbsShape*>& shapes, double& yMin, double& yMax) const;
48 
49  private:
50 
51  bool drawRef(const char* title, const AbsShape* reference, const AbsShape* refSamples, bool first = true, TLegend* legend = 0) const;
52  bool drawData(const char* title, const std::vector<const AbsShape*>& shapes, const AbsShape* reference, bool first = true, TLegend* legend = 0) const;
53 
54  int m_pars;
55  };
56 }
57 #endif
make_hlt_rep.pars
pars
Definition: make_hlt_rep.py:90
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
LArSamples::SamplingTimeUnits
@ SamplingTimeUnits
Definition: ShapeDrawer.h:22
LArSamples::ShapeDrawer::ShapeDrawer
ShapeDrawer(int pars)
Constructor (takes ownership of LArCellInfo object)
Definition: ShapeDrawer.h:31
LArSamples::DrawParams
DrawParams
Definition: ShapeDrawer.h:22
ATLAS_NOT_THREAD_SAFE
#define ATLAS_NOT_THREAD_SAFE
getNoisyStrip() Find noisy strips from hitmaps and write out into xml/db formats
Definition: checker_macros.h:212
index
Definition: index.py:1
LArSamples::ShapeDrawer
Definition: ShapeDrawer.h:26
LArSamples
Definition: AbsShape.h:24
reference
Definition: hcg.cxx:437
LArG4FSStartPointFilterLegacy.draw
draw
Definition: LArG4FSStartPointFilterLegacy.py:20
covarianceTool.title
title
Definition: covarianceTool.py:542
LArSamples::ShapeDrawer::m_pars
int m_pars
Definition: ShapeDrawer.h:54
plotBeamSpotVxVal.legend
legend
Definition: plotBeamSpotVxVal.py:98
LArSamples::AtlasStyle
@ AtlasStyle
Definition: ShapeDrawer.h:22
LArSamples::AbsShape
Definition: AbsShape.h:28
DeMoScan.first
bool first
Definition: DeMoScan.py:536
checker_macros.h
Define macros for attributes used to control the static checker.
LArSamples::DataFirst
@ DataFirst
Definition: ShapeDrawer.h:22
Legend
slightly more convenient legend class
Definition: computils.h:333