12 TString fullName=
"ccX",
15 char* file=
"inp/R5112017.lis",
18 char* outDir =
"outBbc/"
21 gROOT->LoadMacro(
"$STAR/StRoot/StMuDSTMaker/COMMON/macros/loadSharedLibraries.C");
22 loadSharedLibraries();
23 cout <<
" loading done " << endl;
24 gSystem->Load(
"myTest1");
29 printf(
"adding muDst from '%s' ....\n",file);
31 muMk =
new StMuDstMaker(0,0,inDir,file,
"MuDst.root",nFiles);
32 TChain* tree=muMk->
chain(); assert(tree);
33 int nEntries=tree->GetEntries();
34 printf(
"total eve in chain =%d\n",nEntries);
38 myMk3->SetHList(&HList);
39 myMk3->readCalib(
"outBbc/bbcEcalib2.dat");
40 myMk3->readCalib(
"outBbc/bbcWcalib2.dat");
41 myMk3->setTdcCalib(2.0);
43 gMessMgr->SwitchOff(
"D");
44 gMessMgr->SwitchOn(
"I");
54 if(eventCounter>=nEve)
break;
59 if(eventCounter%1000!=0)
continue;
61 printf(
"\n\n ====================%d processing ==============\n", eventCounter);
64 printf(
"sorting done, nEve=%d of %d\n",nEve, nEntries);
66 float rate=1.*eventCounter/(t2-t1);
67 float nMnts=(t2-t1)/60.;
68 printf(
"sorting done %d of nEve=%d, CPU rate=%.1f Hz, tot %.1f minutes\n",eventCounter,nEntries,rate,nMnts);
72 fullName+=
".hist.root";
73 TFile f( outDir+fullName,
"recreate");
75 printf(
"%d histos are written to '%s' ...\n",HList.GetEntries(),fullName.Data());
virtual void Clear(Option_t *option="")
User defined functions.
virtual void ls(Option_t *option="") const
TChain * chain()
In read mode, returns pointer to the chain of .MuDst.root files that where selected.
Axample to access muDst and pass it to ezTree analyzis class.