ATLAS Offline Software
LArCalorimeter
LArSamplesMon
src
GraphShape.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
LArSamplesMon/GraphShape.h
"
6
#include <algorithm>
7
8
using namespace
LArSamples
;
9
10
11
GraphShape::GraphShape
(
const
std::vector<double>&
times
,
const
std::vector<double>&
values
,
12
const
std::vector<double>&
errors
)
13
{
14
for
(
unsigned
int
k
= 0;
k
<
times
.size();
k
++)
15
m_points
.emplace_back(
times
[
k
],
values
[
k
],
errors
[
k
]);
16
}
17
18
19
GraphShape::GraphShape
(
const
AbsShape
& shape,
double
scale
,
double
shift)
20
{
21
for
(
unsigned
int
k
= 0;
k
< shape.
nPoints
();
k
++)
22
m_points
.emplace_back(shape.
time
(
k
) + shift, shape.
value
(
k
)*
scale
, shape.
error
(
k
)*
scale
);
23
}
24
25
26
bool
GraphShape::add
(
const
AbsShape
&
other
)
27
{
28
for
(
unsigned
int
k
= 0;
k
<
other
.nPoints();
k
++)
29
m_points
.emplace_back(
other
.time(
k
),
other
.value(
k
),
other
.error(
k
));
30
31
std::sort(
m_points
.begin(),
m_points
.end());
32
return
true
;
33
}
LArSamples::AbsShape::value
virtual double value(unsigned int i) const =0
LArSamples
Definition:
AbsShape.h:24
LArSamples::GraphShape::m_points
std::vector< GraphPoint > m_points
Definition:
GraphShape.h:57
yodamerge_tmp.scale
scale
Definition:
yodamerge_tmp.py:138
python.Bindings.values
values
Definition:
Control/AthenaPython/python/Bindings.py:805
LArSamples::GraphShape::add
bool add(const AbsShape &other)
Definition:
GraphShape.cxx:26
LArSamples::GraphShape::GraphShape
GraphShape(const std::vector< double > ×, const std::vector< double > &values, const std::vector< double > &errors)
Constructor
Definition:
GraphShape.cxx:11
LArSamples::AbsShape::error
virtual double error(unsigned int i) const
Definition:
AbsShape.cxx:24
GraphShape.h
mergePhysValFiles.errors
list errors
Definition:
DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:43
InDetDD::other
@ other
Definition:
InDetDD_Defs.h:16
LArSamples::AbsShape
Definition:
AbsShape.h:28
LArSamples::AbsShape::time
virtual double time(unsigned int i) const =0
plot_times.times
def times(fn)
Definition:
plot_times.py:11
LArSamples::AbsShape::values
TVectorD values(int lwb, int upb) const
Definition:
AbsShape.cxx:135
fitman.k
k
Definition:
fitman.py:528
LArSamples::AbsShape::nPoints
virtual unsigned int nPoints() const =0
Generated on Sun Dec 22 2024 21:10:59 for ATLAS Offline Software by
1.8.18