static std::string tutname = "mp105_processEntryList: ";
static std::string logfile = "mp105_processEntryList.log";
std::vector<std::string> files = {"http://root.cern.ch/files/h1/dstarmb.root",
"http://root.cern.ch/files/h1/dstarp1a.root",
"http://root.cern.ch/files/h1/dstarp1b.root",
"http://root.cern.ch/files/h1/dstarp2.root"};
int mp105_processEntryList()
{
std::cout << tutname << "creating the entry list \n";
auto sumElist = pool.Process(files, doH1fillList, "h42");
if (sumElist) {
sumElist->Print();
} else {
std::cout << tutname << " ERROR creating the entry list \n";
return -1;
}
std::cout << tutname << "processing the entry list with a lambda \n";
auto hListFun = pool.Process(files, doH1useList, *sumElist, "h42");
if (checkH1(hListFun) < 0)
return -1;
if (doFit(hListFun, logfile.c_str()) < 0)
return -1;
selectorPath += "/tree/h1analysisTreeReader.C+";
std::cout << tutname << "processing the entry list with selector '" << selectorPath << "'\n";
sel->SetOption("useList");
auto hListSel = pool.Process(files, *sel, *sumElist, "h42");
if (checkH1(hListSel) < 0)
return -1;
if (doFit(hListSel, logfile.c_str()) < 0)
return -1;
return 0;
}
R__EXTERN TSystem * gSystem
This class provides an interface to process a TTree dataset in parallel with multi-process technology...
static TSelector * GetSelector(const char *filename)
The code in filename is loaded (interpreted or compiled, see below), filename must contain a valid cl...
void Start(Bool_t reset=kTRUE)
Start the stopwatch.
void Print(Option_t *option="") const
Print the real and cpu time passed between the start and stop events.
virtual Int_t RedirectOutput(const char *name, const char *mode="a", RedirectHandle_t *h=0)
Redirect standard output (stdout, stderr) to the specified file.
<a href="http://nbviewer.jupyter.org/url/root.cern.ch/doc/master/notebooks/mp_H1_lambdas....