3 void plTransMass(
int isMC=1,
int type=1){
7 char* dirMC=
"/star/u/stevens4/wAnalysis/ver4.41/out/";
8 char* dirData=
"/star/data05/scratch/stevens4/wAnalysisOut/ver4.41/data/";
10 if(isMC) plMC(dirMC,type);
11 else plData(dirData,type);
19 void plMC(
char* iPath=
"/star/u/stevens4/wAnalysis/ver4.41/out/",
int type=1){
21 char* core0=
"ppWprod_job";
23 TString fullInpName=iPath; fullInpName+=core0;
24 fullInpName+=
".wana.hist.root";
25 fd=
new TFile(fullInpName);
27 printf(
"EROR: input histo file not found, quit\n",fullInpName.Data());
30 printf(
"Opened: %s\n",fullInpName.Data());
33 gStyle->SetPalette(1);
35 char *nameA[]={
"MCWpt",
"MCWpL",
"MChadRecoilPt"};
36 char *nameB[]={
"MCWminusHadRecoilpt",
"MChadRec_Wpt",
"MCdelPhi_Wpt",
"MCdelPhi_Recoilpt"};
37 char *nameC[]={
"MCelectronRecoPt",
"MCelectronGeantPt",
"MCdiffElectronPtvsGeantpt",
"MCelectronRecovsGeant"};
38 char *nameD[]={
"MCneutrinoRecoPt",
"MCneutrinoGeantPt",
"MCdiffNeutrinoPt",
"MCneutrinoRecovsGeant"};
39 char *nameE[]={
"MCeleG_neutrinoG",
"MCmT",
"MCgMT",
"MCGmTminusmT"};
40 char *nameG[]={
"MCRecoilEta_all",
"MCRecoilEta_WetaPos",
"MCRecoilEta_WetaNeg",
"MCRecoilEtaAll_Wpt"};
42 cA=
new TCanvas(
"aa",
"aa",800,600);
44 for(
int i=0;i<3;i++) {
46 h=(TH1F*)fd->Get(nameA[i]);
50 if(type==1) titA+=
".ps";
54 cB=
new TCanvas(
"bb",
"bb",800,600);
56 for(
int i=0;i<4;i++) {
58 h=(TH1F*)fd->Get(nameB[i]);
60 if(i!=0) h->Draw(
"colz");
63 if(type==1) titB+=
".ps";
67 cC=
new TCanvas(
"cc",
"cc",800,600);
69 for(
int i=0;i<4;i++) {
71 h=(TH1F*)fd->Get(nameC[i]);
73 if(i==3 || i==2) h->Draw(
"colz");
76 if(type==1) titC+=
".ps";
80 cD=
new TCanvas(
"dd",
"dd",800,600);
82 for(
int i=0;i<4;i++) {
84 h=(TH1F*)fd->Get(nameD[i]);
86 if(i==3) h->Draw(
"colz");
89 if(type==1) titD+=
".ps";
93 cE=
new TCanvas(
"ee",
"ee",800,600);
95 for(
int i=0;i<4;i++) {
97 h=(TH1F*)fd->Get(nameE[i]);
99 if(i==0) h->Draw(
"colz");
102 if(type==1) titE+=
".ps";
106 cG=
new TCanvas(
"gg",
"gg",800,600);
108 for(
int i=0;i<4;i++) {
110 h=(TH1F*)fd->Get(nameG[i]);
112 if(i==3) h->Draw(
"colz");
115 if(type==1) titG+=
".ps";
123 void plData(
char* iPath=
"/star/data05/scratch/stevens4/wAnalysisOut/ver4.41/",
int type=1){
125 char* core0=
"run9setABCD.wana.hist.root";
126 TString fullInpName=iPath; fullInpName+=core0;
128 fdData=
new TFile(fullInpName);
129 if(! fdData->IsOpen()) {
130 printf(
"EROR: input histo file not found, quit\n",fullInpName);
133 printf(
"Opened: %s\n",fullInpName.Data());
136 gStyle->SetPalette(1);
138 char *nameH[]={
"JShadRecoilPt",
"JSelectronRecoPt",
"JSneutrinoRecoPt",
"JSmT"};
140 cH=
new TCanvas(
"hh",
"hh",800,600);
142 for(
int k=0;k<4;k++) {
144 h=(TH1F*)fdData->Get(nameH[k]);
146 if(k==1) h->Rebin(2);
149 TString titH=
"RecoilData";
150 if(type==1) titH+=
".ps";