// print out info for how many entries we had in the various histograms void scan(const char *infile = "onlmon_clock.root") { cout << " infile " << infile << endl; TFile *f = TFile::Open(infile); TH1* h1[5]; char histname[128]; for(int arm=0;arm<2; arm++){ for(int iorient=0;iorient<2;iorient++){ for(int ipanel=0;ipanel<6;ipanel++){ for(int igap=0;igap<5;igap++) { sprintf(histname,"MUI_twopack%d%d%d%d",arm, igap, ipanel, iorient); h1[igap]=(TH1*)gROOT->FindObject(histname); cout << " histname " << histname << " Entries " << h1[igap]->GetEntries() << endl; } } } } }