CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Public Attributes
TMTQ Class Reference

#include <TMTQ.h>

Public Types

enum  outVar {
  iPeak, iSigma, iFit, iAmpl,
  iTrise, iFwhm, iFw20, iFw80,
  iPed, iPedsig, iSlide, nOutVar
}
 

Public Member Functions

void addEntry (double, double, double, double, double, double, double, double, double, double, double)
 
std::vector< double > get (int)
 
std::vector< double > getAmpl ()
 
std::vector< double > getFit ()
 
std::vector< double > getFw20 ()
 
std::vector< double > getFw80 ()
 
std::vector< double > getFwhm ()
 
std::vector< double > getPeak ()
 
std::vector< double > getPed ()
 
std::vector< double > getPedsig ()
 
std::vector< double > getSigma ()
 
std::vector< double > getSliding ()
 
std::vector< double > getTrise ()
 
void init ()
 
void setCut (int, double, double)
 
 TMTQ ()
 
virtual ~TMTQ ()
 

Public Attributes

double cuts [2][nOutVar]
 
TMommom [nOutVar]
 

Detailed Description

Definition at line 8 of file TMTQ.h.

Member Enumeration Documentation

◆ outVar

Enumerator
iPeak 
iSigma 
iFit 
iAmpl 
iTrise 
iFwhm 
iFw20 
iFw80 
iPed 
iPedsig 
iSlide 
nOutVar 

Definition at line 10 of file TMTQ.h.

Constructor & Destructor Documentation

◆ TMTQ()

TMTQ::TMTQ ( )

Definition at line 17 of file TMTQ.cc.

References init.

17 { init(); }
void init()
Definition: TMTQ.cc:22

◆ ~TMTQ()

TMTQ::~TMTQ ( )
virtual

Definition at line 20 of file TMTQ.cc.

20 {}

Member Function Documentation

◆ addEntry()

void TMTQ::addEntry ( double  peak,
double  sigma,
double  fit,
double  ampl,
double  trise,
double  fwhm,
double  fw20,
double  fw80,
double  ped,
double  pedsig,
double  sliding 
)

Definition at line 30 of file TMTQ.cc.

References L1TowerCalibrationProducer_cfi::fit, and heppy_batch::val.

40  {
41  double val[nOutVar];
42 
43  val[iPeak] = peak;
44  val[iSigma] = sigma;
45  val[iFit] = fit;
46  val[iAmpl] = ampl;
47  val[iTrise] = trise;
48  val[iFwhm] = fwhm;
49  val[iFw20] = fw20;
50  val[iFw80] = fw80;
51  val[iPed] = ped;
52  val[iPedsig] = pedsig;
53  val[iSlide] = sliding;
54 
55  for (int ivar = 0; ivar < nOutVar; ivar++) {
56  mom[ivar]->addEntry(val[ivar]);
57  }
58 }
void addEntry(double val)
Definition: TMom.cc:88
TMom * mom[nOutVar]
Definition: TMTQ.h:14

◆ get()

std::vector< double > TMTQ::get ( int  ivar)

Definition at line 69 of file TMTQ.cc.

Referenced by Options.Options::__getitem__(), betterConfigParser.BetterConfigParser::__updateDict(), submitPVValidationJobs.BetterConfigParser::__updateDict(), data_sources.json_list::as_dicts(), data_sources.json_list::as_table(), util.rrapi.RRApi::columns(), rrapi.RRApi::columns(), util.rrapi.RRApi::count(), rrapi.RRApi::count(), util.rrapi.RRApi::data(), rrapi.RRApi::data(), EcalMatacqAnalyzer::endJob(), data_sources.json_list::first(), betterConfigParser.BetterConfigParser::getCompares(), betterConfigParser.BetterConfigParser::getGeneral(), betterConfigParser.BetterConfigParser::getResultingSection(), submitPVValidationJobs.BetterConfigParser::getResultingSection(), data_sources.json_list::indices(), data_sources.json_list::last(), util.rrapi.RRApi::report(), rrapi.RRApi::report(), rrapi.RRApi::reports(), util.rrapi.RRApi::reports(), util.rrapi.RRApi::tables(), rrapi.RRApi::tables(), rrapi.RRApi::tags(), util.rrapi.RRApi::tags(), util.rrapi.RRApi::templates(), rrapi.RRApi::templates(), util.rrapi.RRApi::workspaces(), and rrapi.RRApi::workspaces().

69  {
70  std::vector<double> res;
71 
72  if (ivar < nOutVar) {
73  res.push_back(mom[ivar]->getMean());
74  res.push_back(mom[ivar]->getRMS());
75  res.push_back(mom[ivar]->getM3());
76  res.push_back(mom[ivar]->getNevt());
77  res.push_back(mom[ivar]->getMin());
78  res.push_back(mom[ivar]->getMax());
79  }
80  return res;
81 }
Definition: Electron.h:6
TMom * mom[nOutVar]
Definition: TMTQ.h:14

◆ getAmpl()

std::vector< double > TMTQ::getAmpl ( )

Definition at line 87 of file TMTQ.cc.

References iAmpl, and x.

87  {
88  std::vector<double> x = get(TMTQ::iAmpl);
89  return x;
90 }

◆ getFit()

std::vector< double > TMTQ::getFit ( )

Definition at line 99 of file TMTQ.cc.

References iFit, and x.

99  {
100  std::vector<double> x = get(TMTQ::iFit);
101  return x;
102 }

◆ getFw20()

std::vector< double > TMTQ::getFw20 ( )

Definition at line 107 of file TMTQ.cc.

References iFw20, and x.

107  {
108  std::vector<double> x = get(TMTQ::iFw20);
109  return x;
110 }

◆ getFw80()

std::vector< double > TMTQ::getFw80 ( )

Definition at line 111 of file TMTQ.cc.

References iFw80, and x.

111  {
112  std::vector<double> x = get(TMTQ::iFw80);
113  return x;
114 }

◆ getFwhm()

std::vector< double > TMTQ::getFwhm ( )

Definition at line 103 of file TMTQ.cc.

References iFwhm, and x.

103  {
104  std::vector<double> x = get(TMTQ::iFwhm);
105  return x;
106 }

◆ getPeak()

std::vector< double > TMTQ::getPeak ( )

Definition at line 83 of file TMTQ.cc.

References iPeak, and x.

83  {
84  std::vector<double> x = get(TMTQ::iPeak);
85  return x;
86 }

◆ getPed()

std::vector< double > TMTQ::getPed ( )

Definition at line 115 of file TMTQ.cc.

References iPed, and x.

115  {
116  std::vector<double> x = get(TMTQ::iPed);
117  return x;
118 }

◆ getPedsig()

std::vector< double > TMTQ::getPedsig ( )

Definition at line 119 of file TMTQ.cc.

References iPedsig, and x.

119  {
120  std::vector<double> x = get(TMTQ::iPedsig);
121  return x;
122 }

◆ getSigma()

std::vector< double > TMTQ::getSigma ( )

Definition at line 91 of file TMTQ.cc.

References iSigma, and x.

91  {
92  std::vector<double> x = get(TMTQ::iSigma);
93  return x;
94 }

◆ getSliding()

std::vector< double > TMTQ::getSliding ( )

Definition at line 123 of file TMTQ.cc.

References iSlide, and x.

123  {
124  std::vector<double> x = get(TMTQ::iSlide);
125  return x;
126 }

◆ getTrise()

std::vector< double > TMTQ::getTrise ( )

Definition at line 95 of file TMTQ.cc.

References iTrise, and x.

95  {
96  std::vector<double> x = get(TMTQ::iTrise);
97  return x;
98 }

◆ init()

void TMTQ::init ( )

Definition at line 22 of file TMTQ.cc.

References cuts, and dqmiolumiharvest::j.

22  {
23  for (int j = 0; j < nOutVar; j++) {
24  cuts[0][j] = 0.0;
25  cuts[1][j] = 10.0e9;
26  mom[j] = new TMom();
27  }
28 }
double cuts[2][nOutVar]
Definition: TMTQ.h:12
Definition: TMom.h:7
TMom * mom[nOutVar]
Definition: TMTQ.h:14

◆ setCut()

void TMTQ::setCut ( int  ivar,
double  mean,
double  sig 
)

Definition at line 60 of file TMTQ.cc.

References cuts, and SiStripPI::mean.

60  {
61  if (ivar < nOutVar) {
62  cuts[0][ivar] = mean - 2.0 * sig;
63  cuts[1][ivar] = mean + 2.0 * sig;
64 
65  mom[ivar]->setCut(cuts[0][ivar], cuts[1][ivar]);
66  }
67 }
void setCut(double, double)
Definition: TMom.cc:72
double cuts[2][nOutVar]
Definition: TMTQ.h:12
TMom * mom[nOutVar]
Definition: TMTQ.h:14

Member Data Documentation

◆ cuts

double TMTQ::cuts[2][nOutVar]

◆ mom

TMom* TMTQ::mom[nOutVar]

Definition at line 14 of file TMTQ.h.