1#ifndef AMPGEN_PROJECTION_H
2#define AMPGEN_PROJECTION_H
30 const std::string& xAxisTitle,
const size_t& nBins,
const double& min,
const double& max,
31 const std::string& units =
"" ) :
Projection( std::function< double( const
Event& )>(
fcn ),
name, xAxisTitle, nBins, min, max, units ) {}
33 const std::string& xAxisTitle,
const size_t& nBins,
const double& min,
const double& max,
34 const std::string& units =
"" );
35 const std::string
name()
const;
36 template <
class eventlist_type,
class... ARGS> TH1D*
operator()(
const eventlist_type& evts,
const ARGS... args)
const
40 template <
class eventlist_type,
class... ARGS> std::tuple<std::vector<TH1D*>, THStack*>
operator()(
const eventlist_type& evts,
41 const keyedFunctors& weightFunction,
const ARGS... args )
const
48 TH1D*
plot(
const std::string& prefix=
"")
const;
51 void setRange(
const double& min,
const double& max )
60 template <
class eventlist_type>
62 template <
class eventlist_type>
79 template <
typename eventlist_type> TH2D* projInternal(
const eventlist_type&,
const ArgumentPack&)
const;
84 TH2D*
plot(
const std::string& prefix=
"")
const;
85 template <
class eventlist_type,
class... ARGS> TH2D*
operator()(
const eventlist_type& evts,
const ARGS... args)
const
#define DECLARE_ARGUMENT(X, Y)
Container for a set of arguments Contains a set of arguments packed from a variadic constructor,...
Encapsulates the final state particles of a single event.
Unary expression that returns .
Projection2D(const Projection &_xAxis, const Projection &_yAxis)
TH2D * plot(const std::string &prefix="") const
std::pair< double, double > operator()(const Event &evt) const
TH2D * operator()(const eventlist_type &evts, const ARGS... args) const
Projection(const std::function< double(const Event &)> &fcn, const std::string &name, const std::string &xAxisTitle, const size_t &nBins, const double &min, const double &max, const std::string &units="")
std::tuple< std::vector< TH1D * >, THStack * > operator()(const eventlist_type &evts, const keyedFunctors &weightFunction, const ARGS... args) const
void setRange(const double &min, const double &max)
std::function< double(const Event &)> m_func
std::function< int(const Event &evt)> binFunctor() const
TH1D * operator()(const eventlist_type &evts, const ARGS... args) const
Projection(const FCN &fcn, const std::string &name, const std::string &xAxisTitle, const size_t &nBins, const double &min, const double &max, const std::string &units="")
friend class Projection2D
const std::string name() const
TH1D * projInternal(const eventlist_type &, const ArgumentPack &) const
private:
TH1D * plot(const std::string &prefix="") const
std::tuple< std::vector< TH1D * >, THStack * > projInternal(const eventlist_type &, const keyedFunctors &, const ArgumentPack &) const
double operator()(const Event &evt) const