|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef INDETTRACKPERFMON_PLOTMGR_H
6 #define INDETTRACKPERFMON_PLOTMGR_H
39 PlotMgr(
const std::string& dirName,
40 const std::string& anaTag,
52 const std::string& folderOverride =
"",
53 const std::string& nameOverride =
"" )
const;
67 const std::string& folderOverride =
"",
68 const std::string& nameOverride =
"" )
74 return StatusCode::RECOVERABLE;
77 return StatusCode::SUCCESS;
111 TH3* pTh3,
float xval,
float yval,
float zval,
float weight=1. )
const;
121 TProfile2D* pTprofile,
float xval,
float yval,
float zval,
float weight=1. )
const;
125 TEfficiency* pTeff,
float value,
bool accepted,
float weight=1. )
const;
129 TEfficiency* pTeff2d,
float xvalue,
float yvalue,
bool accepted,
float weight=1. )
const;
136 P*& pHisto,
const std::vector<float>&
binning,
char axis )
139 ATH_MSG_ERROR(
"Non-valid variable plot binning : " << pHisto->GetName() );
140 return StatusCode::FAILURE;
145 return StatusCode::SUCCESS;
151 P*& pHisto,
const std::vector<float>&
binning,
char axis )
154 ATH_MSG_ERROR(
"Non-valid variable plot binning : " << pHisto->GetName() );
155 return StatusCode::FAILURE;
158 if(
axis ==
'X' ) pHisto->SetBins( binningD.size()-1, binningD.data() );
161 pHisto->GetTotalHistogram()->GetNbinsX(),
162 pHisto->GetTotalHistogram()->GetXaxis()->GetXbins()->GetArray(),
163 binningD.size()-1, binningD.data() );
165 return StatusCode::SUCCESS;
171 P*& pHisto,
unsigned int nBins,
float absMin,
float absMax,
char axis )
175 return StatusCode::SUCCESS;
181 P*& pHisto,
unsigned int nBins,
float absMin,
float absMax,
char axis )
185 return StatusCode::SUCCESS;
191 unsigned int nBins,
float absMin,
float absMax,
192 bool symmetriseAroundZero =
false );
200 #endif // > ! INDETTRACKPERFMON_PLOTMGR_H
StatusCode book(TH1 *&pHisto, const SinglePlotDefinition &def)
Book a TH1 histogram.
Class to store (internally) each plot definition in this package (originally based on the SingleHisto...
std::vector< float > getLogLinearBins(unsigned int nBins, float absMin, float absMax, bool symmetriseAroundZero=false)
Get Log-Linear binning vector inherited from InDetPhysValMonitoring/src/logLinearBinning....
StatusCode setVariableBinsEff(P *&pHisto, const std::vector< float > &binning, char axis)
SetVariableBins (for Efficiencies)
StatusCode setLogLinearBinsEff(P *&pHisto, unsigned int nBins, float absMin, float absMax, char axis)
Set Log-Linear axis (for Efficiencies)
virtual ~PlotMgr()=default
Destructor.
SinglePlotDefinition retrieveDefinition(const std::string &identifier, const std::string &folderOverride="", const std::string &nameOverride="") const
Retrieve a single histogram definition, given the unique string identifier.
def TProfile(*args, **kwargs)
::StatusCode StatusCode
StatusCode definition for legacy code.
Class to provide easy MsgStream access and capabilities.
PlotMgr(const std::string &dirName, const std::string &anaTag, PlotMgr *pParent=nullptr)
Constructor taking parent node and directory name for plots pParent = nullptr by default to book plot...
StatusCode fill(TH1 *pTh1, float value, float weight=1.) const
StatusCode setVariableBins(P *&pHisto, const std::vector< float > &binning, char axis)
SetVariableBins.
StatusCode setLogLinearBins(P *&pHisto, unsigned int nBins, float absMin, float absMax, char axis)
Set Log-Linear axis.
StatusCode retrieveAndBook(P *&pHisto, const std::string &identifier, const std::string &folderOverride="", const std::string &nameOverride="")
#define ATH_MSG_WARNING(x)
StatusCode initialize()
initialize