1 void selectAllM8(
const char* dirname,
const char *fileBase ){
8 gROOT->LoadMacro(
"load2ptLibs.C");
10 TString inFile(dirname);
14 gSystem->Load(
"StEStructPoolSupport.so");
18 TFile *tf =
new TFile(inFile.Data());
21 cout<<
"error opening file "<<endl;
28 const char* oname[] = {
"all",
"soft",
"neck",
"hard",
"softNeck",
"softHar",
"neckHard"};
30 const int _map[6] = {0, 1, 2, 3, 4, 5};
32 int parentSum[3][2] = { 0,0, 1,1, 2,2 };
35 cout <<
"all" << endl;
36 TString fname(dirname); fname +=
"/"; fname += fileBase; fname+=
"all.root";
37 parentSum[0][0] = 0; parentSum[0][1] = 0;
38 parentSum[1][0] = 1; parentSum[1][1] = 1;
39 parentSum[2][0] = 2; parentSum[2][1] = 2;
43 adder.addCuts(fname.Data(),tf,_map,6,parentSum,nParentSum,1);
45 cout <<
"soft" << endl;
46 TString fname(dirname); fname +=
"/"; fname += fileBase; fname+=
"soft.root";
47 parentSum[0][0] = 0; parentSum[0][1] = 0;
51 adder.addCuts(fname.Data(),tf,&ndata,1,parentSum,nParentSum);
53 cout <<
"neck" << endl;
54 TString fname(dirname); fname +=
"/"; fname += fileBase; fname+=
"neck.root";
55 parentSum[0][0] = 1; parentSum[0][1] = 1;
59 adder.addCuts(fname.Data(),tf,&ndata,1,parentSum,nParentSum);
61 cout <<
"hard" << endl;
62 TString fname(dirname); fname +=
"/"; fname += fileBase; fname+=
"hard.root";
63 parentSum[0][0] = 2; parentSum[0][1] = 2;
67 adder.addCuts(fname.Data(),tf,&ndata,1,parentSum,nParentSum);
69 cout <<
"soft-neck" << endl;
70 TString fname(dirname); fname +=
"/"; fname += fileBase; fname+=
"softNeck.root";
71 parentSum[0][0] = 0; parentSum[0][1] = 1;
75 adder.addCuts(fname.Data(),tf,&ndata,1,parentSum,nParentSum);
77 cout <<
"soft-hard" << endl;
78 TString fname(dirname); fname +=
"/"; fname += fileBase; fname+=
"softHard.root";
79 parentSum[0][0] = 0; parentSum[0][1] = 2;
83 adder.addCuts(fname.Data(),tf,&ndata,1,parentSum,nParentSum);
85 cout <<
"neck-hard" << endl;
86 TString fname(dirname); fname +=
"/"; fname += fileBase; fname+=
"neckHard.root";
87 parentSum[0][0] = 1; parentSum[0][1] = 2;
91 adder.addCuts(fname.Data(),tf,&ndata,1,parentSum,nParentSum);
94 for(
int k=1;k<7;k++) {
96 int *ndata = &_map[k];
99 TString fname(dirname);
102 fname+=
"_pairDensities.root";
103 adder.addDensities(fname.Data(),tf);