static std::string tutname = "mp105_processEntryList: ";
static std::string logfile = "mp105_processEntryList.log";
const char *fh1[] = {"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::vector<std::string> files;
for (int i = 0; i < 4; i++) {
files.push_back(fh1[i]);
}
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";
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;
}