ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitHzz4l/Selection/src/plotH4l.cc
Revision: 1.5
Committed: Tue Oct 23 11:39:21 2012 UTC (12 years, 6 months ago) by dkralph
Content type: text/plain
Branch: MAIN
Changes since 1.4: +270 -31 lines
Log Message:
*** empty log message ***

File Contents

# Content
1 #include <iostream>
2 #include <algorithm>
3 #include <iomanip>
4
5 #include "TCanvas.h"
6 #include "TChain.h"
7 #include "TString.h"
8 #include "Various.h"
9 #include "TStyle.h"
10 #include "TRandom.h"
11 #include "TH1D.h"
12
13 #include "Various.h"
14 #include "RunLumiRangeMap.h"
15
16 #include "CPlot.h"
17 #include "FOArgs.h"
18 #include "SampleWeight.h"
19 #include "SelectionFuncs.h"
20 #include "PlotHeaders.h"
21 #include "MitStyleRemix.h"
22
23 #ifndef CMSSW_BASE
24 #define CMSSW_BASE "../../"
25 #endif
26
27 using namespace std;
28 using namespace RooFit;
29 using namespace mithep;
30
31 TCanvas *can;
32 //----------------------------------------------------------------------------------------
33 TString entry_str(TH1D *hist)
34 {
35 stringstream ss;
36 ss << hist->GetEntries();
37 TString str;
38 ss >> str;
39 return str;
40 }
41 //----------------------------------------------------------------------------------------
42 TString integral_str(TH1D *hist, int dummy, bool nullStr) { if(nullStr) return ""; }
43 void makeHTML(FOFlags &ctrl, TString plotLabel);
44 map<TString,map<TString,TH1D*>* > init_hists(FOFlags &ctrl, TString str="");
45
46 //----------------------------------------------------------------------------------------
47 int main(int argc, char** argv)
48 {
49 SetStyle();
50
51 TFile *flatfile = TFile::Open("pass.root","recreate");
52 TTree *flattuple = new TTree("zznt","zznt");
53 unsigned run,evt,channel;
54 float m4lbrvar;
55 flattuple->Branch("run",&run);
56 flattuple->Branch("evt",&evt);
57 flattuple->Branch("m4l",&m4lbrvar);
58 flattuple->Branch("channel",&channel);
59 FOFlags ctrl;
60 parse_foargs( argc, argv, ctrl );
61 ctrl.dump();
62
63 can = new TCanvas("can","can",700,500);
64
65 TString cmsswpath(CMSSW_BASE + TString("/src"));
66 string xspath = (string(cmsswpath)+"/MitPhysics/data/xs.dat");
67 SimpleTable xstab(xspath.c_str());
68
69 vector<CSample*> samplev;
70 TString ntupledir(""),label(""),plotLabel(""),jsonFile("");
71 int puTarget;
72 readConfigFile(ctrl.config, ntupledir, label, plotLabel, jsonFile, puTarget, samplev, &ctrl, init_hists);
73
74 vector<pair<unsigned,unsigned> > runEvtv; // vector to veto duplicate events
75 UInt_t minRun=999999999,maxRun=0;
76 for(unsigned ics=0; ics<samplev.size(); ics++) {
77 CSample *cs = samplev[ics];
78 cout << cs->name << endl;
79 for(unsigned ifs=0; ifs<(cs->fsv).size(); ifs++) {
80 filestuff *fs = (cs->fsv)[ifs];
81 cout << "\t" << fs->fname_ << " " << fs->getentries("zznt"); cout << flush;
82 unsigned nDuplSkipped=0;
83
84 for(unsigned ientry=0; ientry<fs->getentries("zznt"); ientry++) {
85 fs->getentry(ientry,"info","zznt");
86 fs->getentry(ientry,"kinematics","zznt");
87 fs->getentry(ientry,"weights","zznt");
88 fs->getentry(ientry,"angles","zznt");
89 if(fs->get_zz_chain()->GetBranchStatus("smalljetinfo"))
90 fs->getentry(ientry,"smalljetinfo","zznt");
91
92 if(fs->isdata_ && !(fs->dataset_.Contains("fakes"))) {
93 if(!fs->rlrm_.HasRunLumi(pair<unsigned,unsigned> (fs->info->run, fs->info->lumi))) {
94 continue;
95 }
96 setMinMaxRun(fs->info->run, minRun, maxRun);
97 bool dupl = takeCareOfDuplicateEvents(fs->info->run, fs->info->evt, runEvtv, nDuplSkipped);
98 if(dupl) continue;
99 }
100
101 // calculate weights here:
102 // double wgt = fs->isdata_ ? 1 : fs->lumi_*xstab.Get(fs->dataset_)/fs->total_entries_;
103 // cout << "setting wgt to: " << wgt << " = " << fs->lumi_ << "*" << xstab.Get(fs->dataset_) << "/" << fs->total_entries_ << endl;
104
105 double wgt(1);
106 if(!fs->isdata_) {
107 if(fs->weights->npuw < 0 || fs->weights->npuw > 2) cout << "wtf? " << fs->weights->npuw << endl;
108 wgt = fs->lumi_ * fs->weights->w * fs->weights->npuw * fs->weights->woff * fs->weights->won;
109 if(fs->dataset_.Contains("-dkr")) wgt = 1;
110 }
111
112 if(fs->dataset_.Contains("fakes")) {
113 fs->getentry(ientry,"weights","zznt");
114 // wgt = fs->kine->mZ1err;
115 wgt = fs->weights->w;
116 // if(ientry<100) cout << "multiplying by fake weight: " << fs->weights->w << endl;
117 }
118
119 // if(fs->isdata_ && fs->fname_.Contains("r12c")) {
120 if(fs->kine->m4l > 110 && fs->kine->m4l < 140) continue;
121 if(fs->kine->m4l > 300) continue;
122 // }
123
124 run = fs->info->run;
125 evt = fs->info->evt;
126 m4lbrvar = fs->kine->m4l;
127 channel = fs->kine->channel;
128 flattuple->Fill();
129
130 (*(cs->hists)["all"])["run"]->Fill( fs->info->run , wgt);
131 (*(cs->hists)["all"])["npu"]->Fill( fs->info->npu , wgt);
132 (*(cs->hists)["all"])["npv"]->Fill( fs->info->npv , wgt);
133 (*(cs->hists)["all"])["w"]->Fill( fs->weights->w , 1);
134 (*(cs->hists)["all"])["npuw"]->Fill( fs->weights->npuw , 1);
135 (*(cs->hists)["all"])["woff"]->Fill( fs->weights->woff , 1);
136 (*(cs->hists)["all"])["won"]->Fill( fs->weights->won , 1);
137
138 // sctructs for scaling
139 KinematicsStruct kine = *(fs->kine);
140 Angles angles = *(fs->angles);
141
142 double mZ1 = kine.mZ1;
143 double mZ2 = kine.mZ2;
144 double m4l = kine.m4l;
145 (*(cs->hists)["all"])["mZ1"]->Fill( mZ1 , wgt);
146 (*(cs->hists)["all"])["mZ1_zoom"]->Fill( mZ1 , wgt);
147 (*(cs->hists)["all"])["mZ2"]->Fill( mZ2 , wgt);
148 (*(cs->hists)["all"])["m4l"]->Fill( m4l , wgt);
149 (*(cs->hists)["all"])["m4l_lo"]->Fill( m4l , wgt);
150
151 (*(cs->hists)["all"])["costheta1"]->Fill( angles.costheta1 , wgt);
152 (*(cs->hists)["all"])["costheta2"]->Fill( angles.costheta2 , wgt);
153 (*(cs->hists)["all"])["costhetastar"]->Fill( angles.costhetastar , wgt);
154 (*(cs->hists)["all"])["Phi"]->Fill( angles.Phi , wgt);
155 (*(cs->hists)["all"])["Phi1"]->Fill( angles.Phi1 , wgt);
156
157 (*(cs->hists)["all"])["pt4l"]->Fill( kine.ZZpt/m4l , wgt);
158 (*(cs->hists)["all"])["pt4l_log"]->Fill( kine.ZZpt/m4l , wgt);
159 (*(cs->hists)["all"])["y4l"]->Fill( kine.ZZy , wgt);
160 (*(cs->hists)["all"])["Z1pt"]->Fill( kine.Z1pt/m4l , wgt);
161 (*(cs->hists)["all"])["Z1pt_log"]->Fill( kine.Z1pt/m4l , wgt);
162 (*(cs->hists)["all"])["Z2pt"]->Fill( kine.Z2pt/m4l , wgt);
163 (*(cs->hists)["all"])["Z2pt_log"]->Fill( kine.Z2pt/m4l , wgt);
164
165 (*(cs->hists)["all"])["ZZdotZ1"]->Fill( kine.ZZdotZ1/(m4l*mZ1) , wgt);
166 (*(cs->hists)["all"])["ZZdotZ2"]->Fill( kine.ZZdotZ2/(m4l*mZ2) , wgt);
167 (*(cs->hists)["all"])["ZZdotZ1_log"]->Fill( kine.ZZdotZ1/(m4l*mZ1) , wgt);
168 (*(cs->hists)["all"])["ZZdotZ2_log"]->Fill( kine.ZZdotZ2/(m4l*mZ2) , wgt);
169 (*(cs->hists)["all"])["dphi1"]->Fill( kine.ZZptZ1ptCosDphi, wgt);
170 (*(cs->hists)["all"])["dphi2"]->Fill( kine.ZZptZ2ptCosDphi , wgt);
171 (*(cs->hists)["all"])["dphi1_log"]->Fill( kine.ZZptZ1ptCosDphi, wgt);
172 (*(cs->hists)["all"])["dphi2_log"]->Fill( kine.ZZptZ2ptCosDphi , wgt);
173
174 (*(cs->hists)["all"])["nJets"]->Fill( fs->sji->nJets, wgt);
175 (*(cs->hists)["all"])["ptJet1"]->Fill( fs->sji->ptJet1, wgt);
176 (*(cs->hists)["all"])["met"]->Fill( fs->info->met, wgt);
177 (*(cs->hists)["all"])["metphi"]->Fill( fs->info->metphi, wgt);
178 }
179 cout << "\t\tWARNING: skipped " << nDuplSkipped << " duplicate events" << endl;
180 }
181 }
182 cout << "run range: " << setw(12) << minRun << setw(12) << maxRun << endl;
183 gSystem->mkdir(ctrl.outdir+"/"+plotLabel,true);
184 TFile runHistFile(ctrl.outdir+"/"+plotLabel+"/runs.root","recreate");
185 assert(samplev.size() > 0);
186 bool plotShapesOnly=false;
187 map<TString,TH1D*>::iterator it_v;
188 for(it_v=(*(samplev[0]->hists)["all"]).begin(); it_v!=(*(samplev[0]->hists)["all"]).end(); it_v++) {
189 TString var((*it_v).first);
190 CPlot cplot(var,"",(*(samplev[0]->hists)["all"])[var]->GetXaxis()->GetTitle(),"events",ctrl.outdir+"/"+plotLabel+"/plots");
191 double ymax=0;
192 for(unsigned isam=0; isam<samplev.size(); isam++) {
193 CSample *cs = samplev[isam];
194 TH1D *hist = (*(cs->hists)["all"])[var];
195 if(plotShapesOnly) hist->Scale(1./hist->Integral());
196 // if(!var.Contains("Zdot") && !var.Contains("_zoom") && !(var=="pt4l") && !(var=="Z1pt") && !(var=="Z2pt") && !(var=="mZ2"))) shiftOverflows(hist);
197 if(var.Contains("run") || var.Contains("npu")) shiftOverflows(hist);
198 ymax = max(ymax,hist->GetMaximum());
199 if(plotShapesOnly || (cs->isdata && !(cs->name.Contains("fakes")))) {
200 TString tmpstr = plotShapesOnly ? entry_str(hist) : integral_str(hist);//integral_str(hist,999,true);
201 cplot.AddHist1D(hist,cs->legend+": "+tmpstr,plotShapesOnly ? TString("Ehist") : TString("E"),cs->color);
202 } else {
203 cplot.AddToStack(hist,cs->legend+": "+integral_str(hist,4)/*integral_str(hist,4,true)*/,cs->color);
204 }
205 if(cs->isdata && var=="run") {
206 assert(hist->GetBinContent(0)==0 && hist->GetBinContent(hist->GetXaxis()->GetNbins()+1)==0);
207 hist->Write();
208 }
209 }
210 if(var=="w" || var.Contains("_log")) cplot.SetLogy();
211 else {
212 cplot.SetLogy(false);
213 cplot.SetYRange(0,1.2*ymax);
214 }
215 cplot.Draw(can,true,"png");
216 }
217 runHistFile.Close();
218
219 makeHTML(ctrl,plotLabel);
220 flatfile->Write();
221 // flatfile->Close();
222 assert(string("ROOT SUCKS") == string("FALSE"));
223 }
224 //----------------------------------------------------------------------------------------
225 map<TString,map<TString,TH1D*>* > init_hists(FOFlags &ctrl, TString str)
226 {
227 map<TString,map<TString,TH1D*>* > hists;
228 map<TString,TH1D*> *h_4e = new map<TString,TH1D*>; hists["4e"] = h_4e;
229 map<TString,TH1D*> *h_4m = new map<TString,TH1D*>; hists["4m"] = h_4m;
230 map<TString,TH1D*> *h_2e2m = new map<TString,TH1D*>; hists["2e2m"] = h_2e2m;
231 map<TString,TH1D*> *h_all = new map<TString,TH1D*>; hists["all"] = h_all;
232
233 map<TString,TH1D*> *h_vbf = new map<TString,TH1D*>; hists["vbf"] = h_vbf;
234
235 map<TString,map<TString,TH1D*>* >::iterator it_h;
236 int nbins=35;
237 for(it_h=hists.begin(); it_h!=hists.end(); it_h++) {
238 (*((*it_h).second))["run"] = new TH1D(TString("run") +"_"+(*it_h).first+str,";#bf{run};", nbins,160000,196600); (*((*it_h).second))["run"]->Sumw2();
239 (*((*it_h).second))["npu"] = new TH1D(TString("npu") +"_"+(*it_h).first+str,";#bf{NPU};", 50,-0.5,49.5); (*((*it_h).second))["npu"]->Sumw2();
240 (*((*it_h).second))["npv"] = new TH1D(TString("npv") +"_"+(*it_h).first+str,";#bf{NPV};", 50,-0.5,49.5); (*((*it_h).second))["npv"]->Sumw2();
241
242 (*((*it_h).second))["w"] = new TH1D(TString("w") +"_"+(*it_h).first+str,";#bf{W};", nbins,.0000001,.01); (*((*it_h).second))["w"]->Sumw2();
243 (*((*it_h).second))["npuw"] = new TH1D(TString("npuw") +"_"+(*it_h).first+str,";#bf{NPUW};", nbins,0,4); (*((*it_h).second))["npuw"]->Sumw2();
244 (*((*it_h).second))["woff"] = new TH1D(TString("woff") +"_"+(*it_h).first+str,";#bf{WOFF};", nbins,.5,1.5); (*((*it_h).second))["woff"]->Sumw2();
245 (*((*it_h).second))["won"] = new TH1D(TString("won") +"_"+(*it_h).first+str,";#bf{WON};", nbins,.5,1.5); (*((*it_h).second))["won"]->Sumw2();
246
247 (*((*it_h).second))["mZ1"] = new TH1D(TString("mZ1") +"_"+(*it_h).first+str,";#bf{mZ1 [GeV]};", nbins,30,130); (*((*it_h).second))["mZ1"]->Sumw2();
248 (*((*it_h).second))["mZ1_zoom"] = new TH1D(TString("mZ1_zoom") +"_"+(*it_h).first+str,";#bf{mZ1 [GeV]};",nbins,75,105); (*((*it_h).second))["mZ1_zoom"]->Sumw2();
249 (*((*it_h).second))["mZ2"] = new TH1D(TString("mZ2") +"_"+(*it_h).first+str,";#bf{mZ2 [GeV]};", nbins,0,60); (*((*it_h).second))["mZ2"]->Sumw2();
250 (*((*it_h).second))["m4l_lo"] = new TH1D(TString("m4l_lo") +"_"+(*it_h).first+str,";#bf{m4l [GeV]};", 18,100,165); (*((*it_h).second))["m4l_lo"]->Sumw2();
251 (*((*it_h).second))["m4l"] = new TH1D(TString("m4l") +"_"+(*it_h).first+str,";#bf{m4l [GeV]};", nbins,90,600); (*((*it_h).second))["m4l"]->Sumw2();
252
253 (*((*it_h).second))["costheta1"] = new TH1D(TString("costheta1") +"_"+(*it_h).first+str,";#bf{costheta1};", nbins,-1,1); (*((*it_h).second))["costheta1"]->Sumw2();
254 (*((*it_h).second))["costheta2"] = new TH1D(TString("costheta2") +"_"+(*it_h).first+str,";#bf{costheta2};", nbins,-1,1); (*((*it_h).second))["costheta2"]->Sumw2();
255 (*((*it_h).second))["costhetastar"] = new TH1D(TString("costhetastar") +"_"+(*it_h).first+str,";#bf{costhetastar};",nbins,-1,1); (*((*it_h).second))["costhetastar"]->Sumw2();
256 (*((*it_h).second))["Phi"] = new TH1D(TString("Phi") +"_"+(*it_h).first+str,";#bf{Phi};", nbins,-3.15,3.15); (*((*it_h).second))["Phi"]->Sumw2();
257 (*((*it_h).second))["Phi1"] = new TH1D(TString("Phi1") +"_"+(*it_h).first+str,";#bf{Phi1};", nbins,-3.15,3.15); (*((*it_h).second))["Phi1"]->Sumw2();
258
259 (*((*it_h).second))["pt4l"] = new TH1D(TString("pt4l") +"_"+(*it_h).first+str,";#bf{pt4l/m4l};", nbins,0,0.5); (*((*it_h).second))["pt4l"]->Sumw2();
260 (*((*it_h).second))["pt4l_log"] = new TH1D(TString("pt4l_log") +"_"+(*it_h).first+str,";#bf{pt4l/m4l};", nbins,0,1.5); (*((*it_h).second))["pt4l_log"]->Sumw2();
261 (*((*it_h).second))["y4l"] = new TH1D(TString("y4l") +"_"+(*it_h).first+str,";#bf{y4l};", nbins,-2.4,2.4); (*((*it_h).second))["y4l"]->Sumw2();
262 (*((*it_h).second))["Z1pt"] = new TH1D(TString("Z1pt") +"_"+(*it_h).first+str,";#bf{Z1pt/m4l};", nbins,0,0.5); (*((*it_h).second))["Z1pt"]->Sumw2();
263 (*((*it_h).second))["Z1pt_log"] = new TH1D(TString("Z1pt_log") +"_"+(*it_h).first+str,";#bf{Z1pt/m4l};", nbins,0,1.5); (*((*it_h).second))["Z1pt_log"]->Sumw2();
264 (*((*it_h).second))["Z2pt"] = new TH1D(TString("Z2pt") +"_"+(*it_h).first+str,";#bf{Z2pt/m4l};", nbins,0,0.5); (*((*it_h).second))["Z2pt"]->Sumw2();
265 (*((*it_h).second))["Z2pt_log"] = new TH1D(TString("Z2pt_log") +"_"+(*it_h).first+str,";#bf{Z2pt/m4l};", nbins,0,1.5); (*((*it_h).second))["Z2pt_log"]->Sumw2();
266
267 (*((*it_h).second))["ZZdotZ1"] = new TH1D(TString("ZZdotZ1") +"_"+(*it_h).first+str,";#bf{ZZ #bullet Z1/(m4l*mZ1)};", nbins,-.2,2.5); (*((*it_h).second))["ZZdotZ1"]->Sumw2();
268 (*((*it_h).second))["ZZdotZ2"] = new TH1D(TString("ZZdotZ2") +"_"+(*it_h).first+str,";#bf{ZZ #bullet Z2/(m4l*mZ2)};", nbins,-1,3); (*((*it_h).second))["ZZdotZ2"]->Sumw2();
269 (*((*it_h).second))["ZZdotZ1_log"] = new TH1D(TString("ZZdotZ1_log") +"_"+(*it_h).first+str,";#bf{ZZ #bullet Z1/(m4l*mZ1)};", nbins,-1.5,15); (*((*it_h).second))["ZZdotZ1_log"]->Sumw2();
270 (*((*it_h).second))["ZZdotZ2_log"] = new TH1D(TString("ZZdotZ2_log") +"_"+(*it_h).first+str,";#bf{ZZ #bullet Z2/(m4l*mZ2)};", nbins,-1.5,15); (*((*it_h).second))["ZZdotZ2_log"]->Sumw2();
271 (*((*it_h).second))["dphi1"] = new TH1D(TString("dphi1") +"_"+(*it_h).first+str,";#bf{dphi1};", nbins,-1,1); (*((*it_h).second))["dphi1"]->Sumw2();
272 (*((*it_h).second))["dphi2"] = new TH1D(TString("dphi2") +"_"+(*it_h).first+str,";#bf{dphi2};", nbins,-1,1); (*((*it_h).second))["dphi2"]->Sumw2();
273 (*((*it_h).second))["dphi1_log"] = new TH1D(TString("dphi1_log") +"_"+(*it_h).first+str,";#bf{dphi1};", nbins,-1,1); (*((*it_h).second))["dphi1_log"]->Sumw2();
274 (*((*it_h).second))["dphi2_log"] = new TH1D(TString("dphi2_log") +"_"+(*it_h).first+str,";#bf{dphi2};", nbins,-1,1); (*((*it_h).second))["dphi2_log"]->Sumw2();
275
276 (*((*it_h).second))["nJets"] = new TH1D(TString("nJets") +"_"+(*it_h).first+str,";#bf{nJets};", 12,0.5,12.5); (*((*it_h).second))["nJets"]->Sumw2();
277 (*((*it_h).second))["ptJet1"] = new TH1D(TString("ptJet1") +"_"+(*it_h).first+str,";#bf{ptJet1};", nbins,0,150); (*((*it_h).second))["ptJet1"]->Sumw2();
278
279 (*((*it_h).second))["met"] = new TH1D(TString("met") +"_"+(*it_h).first+str,";#bf{met};", nbins,0,40); (*((*it_h).second))["met"]->Sumw2();
280 (*((*it_h).second))["metphi"] = new TH1D(TString("metphi") +"_"+(*it_h).first+str,";#bf{metphi};", nbins,-3.15,3.15); (*((*it_h).second))["metphi"]->Sumw2();
281 (*((*it_h).second))["metDotZZ"] = new TH1D(TString("metDotZZ") +"_"+(*it_h).first+str,";#bf{metDotZZ};", nbins,-500,500); (*((*it_h).second))["metDotZZ"]->Sumw2();
282 }
283
284 return hists;
285 }
286 //--------------------------------------------------------------------------------------------------
287 void makeHTML(FOFlags &ctrl, TString plotLabel)
288 {
289 // TString title(ctrl.inputdir);
290 // title = title(title.Last('/')+1,title.Length());
291 TString title("Full selection: "+plotLabel);
292 TString htmlfname(ctrl.outdir+"/"+plotLabel+"/plots.html");
293 ofstream htmlfile(htmlfname);
294
295 htmlfile << "<!DOCTYPE html" << endl;
296 htmlfile << " PUBLIC \"-//W3C//DTD HTML 3.2//EN\">" << endl;
297 htmlfile << "<html>" << endl;
298
299 htmlfile << "<head><title>"+title+"</title></head>" << endl;
300 htmlfile << "<body bgcolor=\"000000\">" << endl;
301 htmlfile << "<h3 style=\"text-align:left; color:DD6600;\">"+title+"</h3>" << endl;
302
303 htmlfile << "<hr />" << endl;
304 htmlfile << "<h3 style=\"text-align:left; color:DD6600;\">Boson masses:" << endl;
305 htmlfile << "<table border=\"0\" cellspacing=\"5\" width=\"100%\">" << endl;
306
307 htmlfile << "<tr>" << endl;
308 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/mZ1.png\"><img src=\"plots/mZ1.png\" alt=\"plots/mZ1.png\" width=\"100%\"></a></td>" << endl;
309 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/mZ1_zoom.png\"><img src=\"plots/mZ1_zoom.png\" alt=\"plots/mZ1_zoom.png\" width=\"100%\"></a></td>" << endl;
310 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/mZ2.png\"><img src=\"plots/mZ2.png\" alt=\"plots/mZ2.png\" width=\"100%\"></a></td>" << endl;
311 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
312 htmlfile << "</tr>" << endl;
313
314 htmlfile << "<tr>" << endl;
315 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/m4l_lo.png\"><img src=\"plots/m4l_lo.png\" alt=\"plots/m4l_lo.png\" width=\"100%\"></a></td>" << endl;
316 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/m4l.png\"><img src=\"plots/m4l.png\" alt=\"plots/m4l.png\" width=\"100%\"></a></td>" << endl;
317 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
318 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
319 htmlfile << "</tr>" << endl;
320
321 htmlfile << "</table>" << endl;
322 htmlfile << "<hr />" << endl;
323 htmlfile << "<h3 style=\"text-align:left; color:DD6600;\">Angles: " << endl;
324 htmlfile << "<table border=\"0\" cellspacing=\"5\" width=\"100%\">" << endl;
325
326 htmlfile << "<tr>" << endl;
327 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/costheta1.png\"><img src=\"plots/costheta1.png\" alt=\"plots/costheta1.png\" width=\"100%\"></a></td>" << endl;
328 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/costheta2.png\"><img src=\"plots/costheta2.png\" alt=\"plots/costheta2.png\" width=\"100%\"></a></td>" << endl;
329 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/costhetastar.png\"><img src=\"plots/costhetastar.png\" alt=\"plots/costhetastar.png\" width=\"100%\"></a></td>" << endl;
330 htmlfile << "<td width=\"25%\"></td>" << endl;
331 htmlfile << "</tr>" << endl;
332
333 htmlfile << "<tr>" << endl;
334 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/Phi.png\"><img src=\"plots/Phi.png\" alt=\"plots/Phi.png\" width=\"100%\"></a></td>" << endl;
335 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/Phi1.png\"><img src=\"plots/Phi1.png\" alt=\"plots/Phi1.png\" width=\"100%\"></a></td>" << endl;
336 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
337 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
338 htmlfile << "</tr>" << endl;
339
340 htmlfile << "</table>" << endl;
341 htmlfile << "<hr />" << endl;
342 htmlfile << "<h3 style=\"text-align:left; color:DD6600;\">Boson pt variables: " << endl;
343 htmlfile << "<table border=\"0\" cellspacing=\"5\" width=\"100%\">" << endl;
344
345 htmlfile << "<tr>" << endl;
346 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/y4l.png\"><img src=\"plots/y4l.png\" alt=\"plots/y4l.png\" width=\"100%\"></a></td>" << endl;
347 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/pt4l.png\"><img src=\"plots/pt4l.png\" alt=\"plots/pt4l.png\" width=\"100%\"></a></td>" << endl;
348 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/pt4l_log.png\"><img src=\"plots/pt4l_log.png\" alt=\"plots/pt4l_log.png\" width=\"100%\"></a></td>" << endl;
349 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
350 htmlfile << "<tr>" << endl;
351
352 htmlfile << "</tr>" << endl;
353 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/Z1pt.png\"><img src=\"plots/Z1pt.png\" alt=\"plots/Z1pt.png\" width=\"100%\"></a></td>" << endl;
354 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/Z2pt.png\"><img src=\"plots/Z2pt.png\" alt=\"plots/Z2pt.png\" width=\"100%\"></a></td>" << endl;
355 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/Z1pt_log.png\"><img src=\"plots/Z1pt_log.png\" alt=\"plots/Z1pt_log.png\" width=\"100%\"></a></td>" << endl;
356 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/Z2pt_log.png\"><img src=\"plots/Z2pt_log.png\" alt=\"plots/Z2pt_log.png\" width=\"100%\"></a></td>" << endl;
357 htmlfile << "</tr>" << endl;
358
359 htmlfile << "<tr>" << endl;
360 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/ZZdotZ1.png\"><img src=\"plots/ZZdotZ1.png\" alt=\"plots/ZZdotZ1.png\" width=\"100%\"></a></td>" << endl;
361 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/ZZdotZ2.png\"><img src=\"plots/ZZdotZ2.png\" alt=\"plots/ZZdotZ2.png\" width=\"100%\"></a></td>" << endl;
362 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/ZZdotZ1_log.png\"><img src=\"plots/ZZdotZ1_log.png\" alt=\"plots/ZZdotZ1_log.png\" width=\"100%\"></a></td>" << endl;
363 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/ZZdotZ2_log.png\"><img src=\"plots/ZZdotZ2_log.png\" alt=\"plots/ZZdotZ2_log.png\" width=\"100%\"></a></td>" << endl;
364 htmlfile << "</tr>" << endl;
365
366 htmlfile << "<tr>" << endl;
367 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/dphi1.png\"><img src=\"plots/dphi1.png\" alt=\"plots/dphi1.png\" width=\"100%\"></a></td>" << endl;
368 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/dphi2.png\"><img src=\"plots/dphi2.png\" alt=\"plots/dphi2.png\" width=\"100%\"></a></td>" << endl;
369 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/dphi1_log.png\"><img src=\"plots/dphi1_log.png\" alt=\"plots/dphi1_log.png\" width=\"100%\"></a></td>" << endl;
370 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/dphi2_log.png\"><img src=\"plots/dphi2_log.png\" alt=\"plots/dphi2_log.png\" width=\"100%\"></a></td>" << endl;
371 htmlfile << "</tr>" << endl;
372
373 htmlfile << "</table>" << endl;
374 htmlfile << "<hr />" << endl;
375 htmlfile << "<h3 style=\"text-align:left; color:DD6600;\">weights & co.: " << endl;
376 htmlfile << "<table border=\"0\" cellspacing=\"5\" width=\"100%\">" << endl;
377
378 htmlfile << "<tr>" << endl;
379 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/run.png\"><img src=\"plots/run.png\" alt=\"plots/run.png\" width=\"100%\"></a></td>" << endl;
380 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/npu.png\"><img src=\"plots/npu.png\" alt=\"plots/npu.png\" width=\"100%\"></a></td>" << endl;
381 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/npv.png\"><img src=\"plots/npv.png\" alt=\"plots/npv.png\" width=\"100%\"></a></td>" << endl;
382 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
383 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
384 htmlfile << "</tr>" << endl;
385
386 htmlfile << "<tr>" << endl;
387 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/w.png\"><img src=\"plots/w.png\" alt=\"plots/w.png\" width=\"100%\"></a></td>" << endl;
388 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/npuw.png\"><img src=\"plots/npuw.png\" alt=\"plots/npuw.png\" width=\"100%\"></a></td>" << endl;
389 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/woff.png\"><img src=\"plots/woff.png\" alt=\"plots/woff.png\" width=\"100%\"></a></td>" << endl;
390 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/won.png\"><img src=\"plots/won.png\" alt=\"plots/won.png\" width=\"100%\"></a></td>" << endl;
391 htmlfile << "</tr>" << endl;
392
393 htmlfile << "<tr>" << endl;
394 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/nJets.png\"><img src=\"plots/nJets.png\" alt=\"plots/nJets.png\" width=\"100%\"></a></td>" << endl;
395 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/ptJet1.png\"><img src=\"plots/ptJet1.png\" alt=\"plots/ptJet1.png\" width=\"100%\"></a></td>" << endl;
396 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/met.png\"><img src=\"plots/met.png\" alt=\"plots/met.png\" width=\"100%\"></a></td>" << endl;
397 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/metphi.png\"><img src=\"plots/metphi.png\" alt=\"plots/metphi.png\" width=\"100%\"></a></td>" << endl;
398 htmlfile << "</tr>" << endl;
399
400 htmlfile << "<tr>" << endl;
401 htmlfile << "<td width=\"25%\"><a target=\"_blank\" href=\"plots/metDotZZ.png\"><img src=\"plots/metDotZZ.png\" alt=\"plots/metDotZZ.png\" width=\"100%\"></a></td>" << endl;
402 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
403 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
404 htmlfile << "<td width=\"25%\"><a></a></td>" << endl;
405 htmlfile << "</tr>" << endl;
406
407 htmlfile << "</table>" << endl;
408 htmlfile << "<hr />" << endl;
409
410 htmlfile << "</body>" << endl;
411 htmlfile << "</html>" << endl;
412 htmlfile.close();
413 }