Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
Validation
RecoB
interface
HistoCompare.h
Go to the documentation of this file.
1
#ifndef RecoB_HistoCompare_h
2
#define RecoB_HistoCompare_h
3
16
#include "TFile.h"
17
#include "TH1.h"
18
#include "TString.h"
19
20
#include <iostream>
21
#include <string>
22
#include <vector>
23
24
class
HistoCompare
{
25
26
public
:
27
HistoCompare
();
28
HistoCompare
(
const
TString& refFilename);
29
30
~HistoCompare
();
31
32
TH1*
Compare
(TH1*
h
,
const
TString& hname);
33
34
void
SetReferenceFilename
(
const
TString&
filename
) {
35
refFilename_
=
filename
;
36
//if (refFile_) delete refFile_;
37
refFile_
=
new
TFile(
refFilename_
);
38
if
(
refFile_
->IsZombie()) {
39
std::cout
<<
" Error openning file "
<<
refFilename_
<< std::endl;
40
std::cout
<<
" we will not compare histograms. "
<< std::endl;
41
do_nothing_
=
true
;
42
}
43
std::cout
<<
" open file"
<< std::endl;
44
};
45
46
void
SetChi2Test
(
bool
test
=
true
) {
47
setChi2Test_
=
test
;
48
};
49
50
void
SetKGTest
(
bool
test
=
true
) {
51
setKGTest_
=
test
;
52
};
53
54
double
GetResult
() {
return
result_
; };
55
56
private
:
57
58
bool
setChi2Test_
;
59
bool
setKGTest_
;
60
double
result_
;
61
bool
do_nothing_
;
62
63
TH1 *
resHisto_
;
64
TH1 *
refHisto_
;
65
TFile *
refFile_
;
66
67
TString
refFilename_
;
68
69
//std::map<std::string, TH1*> histomap_;
70
71
};
72
73
#endif
HistoCompare::SetReferenceFilename
void SetReferenceFilename(const TString &filename)
Definition:
HistoCompare.h:34
HistoCompare
Definition:
HistoCompare.h:24
HistoCompare::result_
double result_
Definition:
HistoCompare.h:60
HistoCompare::resHisto_
TH1 * resHisto_
Definition:
HistoCompare.h:63
HistoCompare::do_nothing_
bool do_nothing_
Definition:
HistoCompare.h:61
HistoCompare::refHisto_
TH1 * refHisto_
Definition:
HistoCompare.h:64
HistoCompare::GetResult
double GetResult()
Definition:
HistoCompare.h:54
HistoCompare::SetKGTest
void SetKGTest(bool test=true)
Definition:
HistoCompare.h:50
HistoCompare::refFilename_
TString refFilename_
Definition:
HistoCompare.h:67
h
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition:
Activities.doc:4
HistoCompare::~HistoCompare
~HistoCompare()
Definition:
HistoCompare.cc:39
HistoCompare::HistoCompare
HistoCompare()
Definition:
HistoCompare.cc:16
HistoCompare::SetChi2Test
void SetChi2Test(bool test=true)
Definition:
HistoCompare.h:46
run_regression.test
tuple test
Definition:
run_regression.py:386
lut2db_cfg.filename
tuple filename
Definition:
lut2db_cfg.py:20
gather_cfg.cout
tuple cout
Definition:
gather_cfg.py:121
HistoCompare::setChi2Test_
bool setChi2Test_
Definition:
HistoCompare.h:54
HistoCompare::refFile_
TFile * refFile_
Definition:
HistoCompare.h:65
HistoCompare::setKGTest_
bool setKGTest_
Definition:
HistoCompare.h:59
HistoCompare::Compare
TH1 * Compare(TH1 *h, const TString &hname)
Definition:
HistoCompare.cc:43
Generated for CMSSW Reference Manual by
1.8.5