25int main(
int argc,
char **argv)
39 JParser<> zap(
"Example program to histogram energy corrections.");
43 zap[
'x'] =
make_field(X,
"axis range in log(E/GeV)");
48 catch(
const exception& error) {
49 FATAL(error.what() << endl);
53 JManager<string, TH1D> zmap(
new TH1D(
"h[%]", NULL, 1000, X.getLowerLimit(), X.getUpperLimit()));
55 for (vector<string>::const_iterator f1 = energy_correction.begin(); f1 != energy_correction.end(); ++f1) {
59 DEBUG(getFilename(*f1) << endl << fcn << endl);
61 for (
int i = 1; i <= zmap->GetNbinsX(); ++i) {
63 const double x = zmap->GetBinCenter (i);
64 const double E = pow(10.0, x);
65 const double y = fcn(E) / E;
67 zmap[getFilename(*f1)]->SetBinContent(i, y);
Dynamic ROOT object management.
General purpose messaging.
#define DEBUG(A)
Message macros.
Utility class to parse command line options.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
Auxiliary class to define a range between two values.
Utility class to parse command line options.
Auxiliary class for correction of energy determined by JEnergy.cc.
int main(int argc, char **argv)
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).