void LCTsigma_2016B_June22all_sameYrange() { //=========Macro generated from canvas: LCTsigma/LCTsigma //========= (Fri Aug 5 08:12:17 2016) by ROOT version6.06/01 TCanvas *LCTsigma = new TCanvas("LCTsigma", "LCTsigma",0,0,500,500); gStyle->SetOptStat(0); LCTsigma->SetHighLightColor(2); LCTsigma->Range(-5,-2.848556,45,2.626708); LCTsigma->SetFillColor(0); LCTsigma->SetBorderMode(0); LCTsigma->SetBorderSize(2); LCTsigma->SetLogy(); LCTsigma->SetFrameBorderMode(0); LCTsigma->SetFrameBorderMode(0); TH1D *LCTsigma_1__61 = new TH1D("LCTsigma_1__61","LCTsigma",100,0,40); LCTsigma_1__61->SetBinContent(1,0.2671004); LCTsigma_1__61->SetBinContent(2,0.7179271); LCTsigma_1__61->SetBinContent(3,82.27739); LCTsigma_1__61->SetBinContent(4,1.049605); LCTsigma_1__61->SetBinContent(5,1.020196); LCTsigma_1__61->SetBinContent(6,0.9397023); LCTsigma_1__61->SetBinContent(7,0.8736094); LCTsigma_1__61->SetBinContent(8,0.8270714); LCTsigma_1__61->SetBinContent(9,0.7708318); LCTsigma_1__61->SetBinContent(10,0.7038293); LCTsigma_1__61->SetBinContent(11,0.648196); LCTsigma_1__61->SetBinContent(12,0.6174234); LCTsigma_1__61->SetBinContent(13,0.5702791); LCTsigma_1__61->SetBinContent(14,0.5160101); LCTsigma_1__61->SetBinContent(15,0.4749294); LCTsigma_1__61->SetBinContent(16,0.4242986); LCTsigma_1__61->SetBinContent(17,0.4070174); LCTsigma_1__61->SetBinContent(18,0.3483523); LCTsigma_1__61->SetBinContent(19,0.3169733); LCTsigma_1__61->SetBinContent(20,0.2802887); LCTsigma_1__61->SetBinContent(21,0.2570955); LCTsigma_1__61->SetBinContent(22,0.2293547); LCTsigma_1__61->SetBinContent(23,0.2028265); LCTsigma_1__61->SetBinContent(24,0.1869097); LCTsigma_1__61->SetBinContent(25,0.1802397); LCTsigma_1__61->SetBinContent(26,0.1635649); LCTsigma_1__61->SetBinContent(27,0.1508314); LCTsigma_1__61->SetBinContent(28,0.1462837); LCTsigma_1__61->SetBinContent(29,0.1315795); LCTsigma_1__61->SetBinContent(30,0.1312764); LCTsigma_1__61->SetBinContent(31,0.124758); LCTsigma_1__61->SetBinContent(32,0.1168754); LCTsigma_1__61->SetBinContent(33,0.1152079); LCTsigma_1__61->SetBinContent(34,0.1083864); LCTsigma_1__61->SetBinContent(35,0.1139952); LCTsigma_1__61->SetBinContent(36,0.09428857); LCTsigma_1__61->SetBinContent(37,0.100049); LCTsigma_1__61->SetBinContent(38,0.096714); LCTsigma_1__61->SetBinContent(39,0.1030808); LCTsigma_1__61->SetBinContent(40,0.09353062); LCTsigma_1__61->SetBinContent(41,0.09610764); LCTsigma_1__61->SetBinContent(42,0.09155996); LCTsigma_1__61->SetBinContent(43,0.08943771); LCTsigma_1__61->SetBinContent(44,0.08928612); LCTsigma_1__61->SetBinContent(45,0.08200983); LCTsigma_1__61->SetBinContent(46,0.0867091); LCTsigma_1__61->SetBinContent(47,0.08170665); LCTsigma_1__61->SetBinContent(48,0.07761374); LCTsigma_1__61->SetBinContent(49,0.08489003); LCTsigma_1__61->SetBinContent(50,0.0811003); LCTsigma_1__61->SetBinContent(51,0.0739756); LCTsigma_1__61->SetBinContent(52,0.07079222); LCTsigma_1__61->SetBinContent(53,0.07352083); LCTsigma_1__61->SetBinContent(54,0.06988269); LCTsigma_1__61->SetBinContent(55,0.07094381); LCTsigma_1__61->SetBinContent(56,0.06776043); LCTsigma_1__61->SetBinContent(57,0.06503183); LCTsigma_1__61->SetBinContent(58,0.05699759); LCTsigma_1__61->SetBinContent(59,0.06002938); LCTsigma_1__61->SetBinContent(60,0.06169686); LCTsigma_1__61->SetBinContent(61,0.05533011); LCTsigma_1__61->SetBinContent(62,0.05927143); LCTsigma_1__61->SetBinContent(63,0.0554817); LCTsigma_1__61->SetBinContent(64,0.05623964); LCTsigma_1__61->SetBinContent(65,0.05320786); LCTsigma_1__61->SetBinContent(66,0.05290468); LCTsigma_1__61->SetBinContent(67,0.04593157); LCTsigma_1__61->SetBinContent(68,0.05351104); LCTsigma_1__61->SetBinContent(69,0.04987289); LCTsigma_1__61->SetBinContent(70,0.0539658); LCTsigma_1__61->SetBinContent(71,0.04699269); LCTsigma_1__61->SetBinContent(72,0.04593157); LCTsigma_1__61->SetBinContent(73,0.04365773); LCTsigma_1__61->SetBinContent(74,0.04532521); LCTsigma_1__61->SetBinContent(75,0.04062594); LCTsigma_1__61->SetBinContent(76,0.04380932); LCTsigma_1__61->SetBinContent(77,0.04001959); LCTsigma_1__61->SetBinContent(78,0.039868); LCTsigma_1__61->SetBinContent(79,0.03926164); LCTsigma_1__61->SetBinContent(80,0.04017117); LCTsigma_1__61->SetBinContent(81,0.03683621); LCTsigma_1__61->SetBinContent(82,0.03607826); LCTsigma_1__61->SetBinContent(83,0.03350124); LCTsigma_1__61->SetBinContent(84,0.03228853); LCTsigma_1__61->SetBinContent(85,0.03683621); LCTsigma_1__61->SetBinContent(86,0.03259171); LCTsigma_1__61->SetBinContent(87,0.03213694); LCTsigma_1__61->SetBinContent(88,0.03107581); LCTsigma_1__61->SetBinContent(89,0.03153058); LCTsigma_1__61->SetBinContent(90,0.02895356); LCTsigma_1__61->SetBinContent(91,0.03153058); LCTsigma_1__61->SetBinContent(92,0.03244012); LCTsigma_1__61->SetBinContent(93,0.02743767); LCTsigma_1__61->SetBinContent(94,0.03077264); LCTsigma_1__61->SetBinContent(95,0.02592178); LCTsigma_1__61->SetBinContent(96,0.0284988); LCTsigma_1__61->SetBinContent(97,0.02713449); LCTsigma_1__61->SetBinContent(98,0.02592178); LCTsigma_1__61->SetBinContent(99,0.02789244); LCTsigma_1__61->SetBinContent(100,0.02031297); LCTsigma_1__61->SetBinContent(101,2.444378); LCTsigma_1__61->SetMinimum(0.005); LCTsigma_1__61->SetMaximum(120); LCTsigma_1__61->SetEntries(675802); LCTsigma_1__61->SetStats(0); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#ff00ff"); LCTsigma_1__61->SetLineColor(ci); ci = TColor::GetColor("#ff00ff"); LCTsigma_1__61->SetMarkerColor(ci); LCTsigma_1__61->GetXaxis()->SetTitle("cm"); LCTsigma_1__61->GetYaxis()->SetTitle("scaled number of entries"); LCTsigma_1__61->Draw("H"); TLegend *leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); TLegendEntry *entry=leg->AddEntry("LCTsigma_1","ME11A: mean:2.4cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_2","ME11B: mean:2.1cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_3","ME12+13: mean:1.5cm;RMS:2.4cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_4","ME2: mean:1.4cm;RMS:2.2cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_5","ME3: mean:1.3cm;RMS:1.6cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_6","ME4: mean:1.3cm;RMS:1.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *LCTsigma_2__62 = new TH1D("LCTsigma_2__62","LCTsigma",100,0,40); LCTsigma_2__62->SetBinContent(1,0.6415878); LCTsigma_2__62->SetBinContent(2,1.663795); LCTsigma_2__62->SetBinContent(3,76.94018); LCTsigma_2__62->SetBinContent(4,2.312834); LCTsigma_2__62->SetBinContent(5,2.146591); LCTsigma_2__62->SetBinContent(6,1.90712); LCTsigma_2__62->SetBinContent(7,1.670475); LCTsigma_2__62->SetBinContent(8,1.464321); LCTsigma_2__62->SetBinContent(9,1.276495); LCTsigma_2__62->SetBinContent(10,1.093637); LCTsigma_2__62->SetBinContent(11,0.9240544); LCTsigma_2__62->SetBinContent(12,0.801578); LCTsigma_2__62->SetBinContent(13,0.6547776); LCTsigma_2__62->SetBinContent(14,0.5377827); LCTsigma_2__62->SetBinContent(15,0.4390307); LCTsigma_2__62->SetBinContent(16,0.3703412); LCTsigma_2__62->SetBinContent(17,0.3101308); LCTsigma_2__62->SetBinContent(18,0.2571148); LCTsigma_2__62->SetBinContent(19,0.2253394); LCTsigma_2__62->SetBinContent(20,0.1915085); LCTsigma_2__62->SetBinContent(21,0.1732655); LCTsigma_2__62->SetBinContent(22,0.1490272); LCTsigma_2__62->SetBinContent(23,0.1475712); LCTsigma_2__62->SetBinContent(24,0.134724); LCTsigma_2__62->SetBinContent(25,0.121363); LCTsigma_2__62->SetBinContent(26,0.1187079); LCTsigma_2__62->SetBinContent(27,0.1096292); LCTsigma_2__62->SetBinContent(28,0.1087727); LCTsigma_2__62->SetBinContent(29,0.09858064); LCTsigma_2__62->SetBinContent(30,0.09840935); LCTsigma_2__62->SetBinContent(31,0.09858064); LCTsigma_2__62->SetBinContent(32,0.08796031); LCTsigma_2__62->SetBinContent(33,0.08504829); LCTsigma_2__62->SetBinContent(34,0.08230756); LCTsigma_2__62->SetBinContent(35,0.07956683); LCTsigma_2__62->SetBinContent(36,0.08033766); LCTsigma_2__62->SetBinContent(37,0.07691175); LCTsigma_2__62->SetBinContent(38,0.07408537); LCTsigma_2__62->SetBinContent(39,0.06749048); LCTsigma_2__62->SetBinContent(40,0.06517799); LCTsigma_2__62->SetBinContent(41,0.06654836); LCTsigma_2__62->SetBinContent(42,0.0689465); LCTsigma_2__62->SetBinContent(43,0.06671965); LCTsigma_2__62->SetBinContent(44,0.06166643); LCTsigma_2__62->SetBinContent(45,0.0608956); LCTsigma_2__62->SetBinContent(46,0.05601368); LCTsigma_2__62->SetBinContent(47,0.05661321); LCTsigma_2__62->SetBinContent(48,0.05635627); LCTsigma_2__62->SetBinContent(49,0.05395813); LCTsigma_2__62->SetBinContent(50,0.05130305); LCTsigma_2__62->SetBinContent(51,0.04659242); LCTsigma_2__62->SetBinContent(52,0.04753454); LCTsigma_2__62->SetBinContent(53,0.05147434); LCTsigma_2__62->SetBinContent(54,0.0451364); LCTsigma_2__62->SetBinContent(55,0.04719195); LCTsigma_2__62->SetBinContent(56,0.04650677); LCTsigma_2__62->SetBinContent(57,0.04410863); LCTsigma_2__62->SetBinContent(58,0.04231002); LCTsigma_2__62->SetBinContent(59,0.03837022); LCTsigma_2__62->SetBinContent(60,0.04273826); LCTsigma_2__62->SetBinContent(61,0.03699986); LCTsigma_2__62->SetBinContent(62,0.03614338); LCTsigma_2__62->SetBinContent(63,0.03485866); LCTsigma_2__62->SetBinContent(64,0.03400219); LCTsigma_2__62->SetBinContent(65,0.03657162); LCTsigma_2__62->SetBinContent(66,0.03811328); LCTsigma_2__62->SetBinContent(67,0.03263182); LCTsigma_2__62->SetBinContent(68,0.03263182); LCTsigma_2__62->SetBinContent(69,0.03425913); LCTsigma_2__62->SetBinContent(70,0.03023368); LCTsigma_2__62->SetBinContent(71,0.03246052); LCTsigma_2__62->SetBinContent(72,0.02971979); LCTsigma_2__62->SetBinContent(73,0.03091886); LCTsigma_2__62->SetBinContent(74,0.03186099); LCTsigma_2__62->SetBinContent(75,0.02749295); LCTsigma_2__62->SetBinContent(76,0.02774989); LCTsigma_2__62->SetBinContent(77,0.02800684); LCTsigma_2__62->SetBinContent(78,0.02612259); LCTsigma_2__62->SetBinContent(79,0.02620823); LCTsigma_2__62->SetBinContent(80,0.02792119); LCTsigma_2__62->SetBinContent(81,0.02663647); LCTsigma_2__62->SetBinContent(82,0.02415269); LCTsigma_2__62->SetBinContent(83,0.02381009); LCTsigma_2__62->SetBinContent(84,0.02637953); LCTsigma_2__62->SetBinContent(85,0.02415269); LCTsigma_2__62->SetBinContent(86,0.02329621); LCTsigma_2__62->SetBinContent(87,0.02201149); LCTsigma_2__62->SetBinContent(88,0.02286797); LCTsigma_2__62->SetBinContent(89,0.01901382); LCTsigma_2__62->SetBinContent(90,0.02201149); LCTsigma_2__62->SetBinContent(91,0.02312491); LCTsigma_2__62->SetBinContent(92,0.01901382); LCTsigma_2__62->SetBinContent(93,0.01858558); LCTsigma_2__62->SetBinContent(94,0.01807169); LCTsigma_2__62->SetBinContent(95,0.02192584); LCTsigma_2__62->SetBinContent(96,0.02004159); LCTsigma_2__62->SetBinContent(97,0.01721521); LCTsigma_2__62->SetBinContent(98,0.01867123); LCTsigma_2__62->SetBinContent(99,0.01841428); LCTsigma_2__62->SetBinContent(100,0.01849993); LCTsigma_2__62->SetBinContent(101,1.521876); LCTsigma_2__62->SetEntries(1185341); LCTsigma_2__62->SetStats(0); ci = TColor::GetColor("#ff9999"); LCTsigma_2__62->SetLineColor(ci); ci = TColor::GetColor("#ff9999"); LCTsigma_2__62->SetMarkerColor(ci); LCTsigma_2__62->GetXaxis()->SetTitle("cm"); LCTsigma_2__62->GetYaxis()->SetTitle("scaled number of entries"); LCTsigma_2__62->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("LCTsigma_1","ME11A: mean:2.4cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_2","ME11B: mean:2.1cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_3","ME12+13: mean:1.5cm;RMS:2.4cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_4","ME2: mean:1.4cm;RMS:2.2cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_5","ME3: mean:1.3cm;RMS:1.6cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_6","ME4: mean:1.3cm;RMS:1.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *LCTsigma_3__63 = new TH1D("LCTsigma_3__63","LCTsigma",100,0,40); LCTsigma_3__63->SetBinContent(1,3.18335); LCTsigma_3__63->SetBinContent(2,8.110099); LCTsigma_3__63->SetBinContent(3,55.60834); LCTsigma_3__63->SetBinContent(4,9.726071); LCTsigma_3__63->SetBinContent(5,7.599615); LCTsigma_3__63->SetBinContent(6,5.331); LCTsigma_3__63->SetBinContent(7,3.482403); LCTsigma_3__63->SetBinContent(8,2.167811); LCTsigma_3__63->SetBinContent(9,1.28797); LCTsigma_3__63->SetBinContent(10,0.7526726); LCTsigma_3__63->SetBinContent(11,0.4709373); LCTsigma_3__63->SetBinContent(12,0.3124935); LCTsigma_3__63->SetBinContent(13,0.2109138); LCTsigma_3__63->SetBinContent(14,0.146554); LCTsigma_3__63->SetBinContent(15,0.1157958); LCTsigma_3__63->SetBinContent(16,0.085296); LCTsigma_3__63->SetBinContent(17,0.06927069); LCTsigma_3__63->SetBinContent(18,0.05841484); LCTsigma_3__63->SetBinContent(19,0.05712247); LCTsigma_3__63->SetBinContent(20,0.04471578); LCTsigma_3__63->SetBinContent(21,0.03515229); LCTsigma_3__63->SetBinContent(22,0.03618618); LCTsigma_3__63->SetBinContent(23,0.03515229); LCTsigma_3__63->SetBinContent(24,0.03153367); LCTsigma_3__63->SetBinContent(25,0.02817353); LCTsigma_3__63->SetBinContent(26,0.0341184); LCTsigma_3__63->SetBinContent(27,0.02481338); LCTsigma_3__63->SetBinContent(28,0.02197018); LCTsigma_3__63->SetBinContent(29,0.02739811); LCTsigma_3__63->SetBinContent(30,0.01964393); LCTsigma_3__63->SetBinContent(31,0.02429644); LCTsigma_3__63->SetBinContent(32,0.01938546); LCTsigma_3__63->SetBinContent(33,0.02041935); LCTsigma_3__63->SetBinContent(34,0.01783462); LCTsigma_3__63->SetBinContent(35,0.02067782); LCTsigma_3__63->SetBinContent(36,0.01861004); LCTsigma_3__63->SetBinContent(37,0.01938546); LCTsigma_3__63->SetBinContent(38,0.01524989); LCTsigma_3__63->SetBinContent(39,0.01886851); LCTsigma_3__63->SetBinContent(40,0.01783462); LCTsigma_3__63->SetBinContent(41,0.01757615); LCTsigma_3__63->SetBinContent(42,0.01938546); LCTsigma_3__63->SetBinContent(43,0.01524989); LCTsigma_3__63->SetBinContent(44,0.01757615); LCTsigma_3__63->SetBinContent(45,0.01731767); LCTsigma_3__63->SetBinContent(46,0.01731767); LCTsigma_3__63->SetBinContent(47,0.01964393); LCTsigma_3__63->SetBinContent(48,0.01628378); LCTsigma_3__63->SetBinContent(49,0.01550836); LCTsigma_3__63->SetBinContent(50,0.01524989); LCTsigma_3__63->SetBinContent(51,0.01524989); LCTsigma_3__63->SetBinContent(52,0.01395753); LCTsigma_3__63->SetBinContent(53,0.01369906); LCTsigma_3__63->SetBinContent(54,0.01628378); LCTsigma_3__63->SetBinContent(55,0.01059738); LCTsigma_3__63->SetBinContent(56,0.01163127); LCTsigma_3__63->SetBinContent(57,0.009563491); LCTsigma_3__63->SetBinContent(58,0.01033891); LCTsigma_3__63->SetBinContent(59,0.01369906); LCTsigma_3__63->SetBinContent(60,0.01395753); LCTsigma_3__63->SetBinContent(61,0.009046546); LCTsigma_3__63->SetBinContent(62,0.01292364); LCTsigma_3__63->SetBinContent(63,0.009305019); LCTsigma_3__63->SetBinContent(64,0.01085585); LCTsigma_3__63->SetBinContent(65,0.01188975); LCTsigma_3__63->SetBinContent(66,0.01008044); LCTsigma_3__63->SetBinContent(67,0.01344058); LCTsigma_3__63->SetBinContent(68,0.01292364); LCTsigma_3__63->SetBinContent(69,0.0113728); LCTsigma_3__63->SetBinContent(70,0.01163127); LCTsigma_3__63->SetBinContent(71,0.01033891); LCTsigma_3__63->SetBinContent(72,0.0113728); LCTsigma_3__63->SetBinContent(73,0.0113728); LCTsigma_3__63->SetBinContent(74,0.009821964); LCTsigma_3__63->SetBinContent(75,0.0113728); LCTsigma_3__63->SetBinContent(76,0.01240669); LCTsigma_3__63->SetBinContent(77,0.01214822); LCTsigma_3__63->SetBinContent(78,0.01111433); LCTsigma_3__63->SetBinContent(79,0.008788073); LCTsigma_3__63->SetBinContent(80,0.01008044); LCTsigma_3__63->SetBinContent(81,0.006978764); LCTsigma_3__63->SetBinContent(82,0.007754182); LCTsigma_3__63->SetBinContent(83,0.01344058); LCTsigma_3__63->SetBinContent(84,0.009305019); LCTsigma_3__63->SetBinContent(85,0.01008044); LCTsigma_3__63->SetBinContent(86,0.01085585); LCTsigma_3__63->SetBinContent(87,0.009046546); LCTsigma_3__63->SetBinContent(88,0.008271128); LCTsigma_3__63->SetBinContent(89,0.009305019); LCTsigma_3__63->SetBinContent(90,0.0085296); LCTsigma_3__63->SetBinContent(91,0.009821964); LCTsigma_3__63->SetBinContent(92,0.009821964); LCTsigma_3__63->SetBinContent(93,0.009046546); LCTsigma_3__63->SetBinContent(94,0.008788073); LCTsigma_3__63->SetBinContent(95,0.007237237); LCTsigma_3__63->SetBinContent(96,0.008271128); LCTsigma_3__63->SetBinContent(97,0.006203346); LCTsigma_3__63->SetBinContent(98,0.006203346); LCTsigma_3__63->SetBinContent(99,0.005944873); LCTsigma_3__63->SetBinContent(100,0.005169455); LCTsigma_3__63->SetBinContent(101,0.6999442); LCTsigma_3__63->SetEntries(389596); LCTsigma_3__63->SetStats(0); LCTsigma_3__63->GetXaxis()->SetTitle("cm"); LCTsigma_3__63->GetYaxis()->SetTitle("scaled number of entries"); LCTsigma_3__63->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("LCTsigma_1","ME11A: mean:2.4cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_2","ME11B: mean:2.1cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_3","ME12+13: mean:1.5cm;RMS:2.4cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_4","ME2: mean:1.4cm;RMS:2.2cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_5","ME3: mean:1.3cm;RMS:1.6cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_6","ME4: mean:1.3cm;RMS:1.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *LCTsigma_4__64 = new TH1D("LCTsigma_4__64","LCTsigma",100,0,40); LCTsigma_4__64->SetBinContent(1,1.8811); LCTsigma_4__64->SetBinContent(2,4.878654); LCTsigma_4__64->SetBinContent(3,73.17773); LCTsigma_4__64->SetBinContent(4,5.69795); LCTsigma_4__64->SetBinContent(5,4.447017); LCTsigma_4__64->SetBinContent(6,3.067821); LCTsigma_4__64->SetBinContent(7,1.963316); LCTsigma_4__64->SetBinContent(8,1.222624); LCTsigma_4__64->SetBinContent(9,0.7509952); LCTsigma_4__64->SetBinContent(10,0.4758781); LCTsigma_4__64->SetBinContent(11,0.3264227); LCTsigma_4__64->SetBinContent(12,0.2169601); LCTsigma_4__64->SetBinContent(13,0.1604495); LCTsigma_4__64->SetBinContent(14,0.1189164); LCTsigma_4__64->SetBinContent(15,0.09953076); LCTsigma_4__64->SetBinContent(16,0.07902976); LCTsigma_4__64->SetBinContent(17,0.06771703); LCTsigma_4__64->SetBinContent(18,0.06442413); LCTsigma_4__64->SetBinContent(19,0.05651053); LCTsigma_4__64->SetBinContent(20,0.05146495); LCTsigma_4__64->SetBinContent(21,0.04641936); LCTsigma_4__64->SetBinContent(22,0.04243601); LCTsigma_4__64->SetBinContent(23,0.04254223); LCTsigma_4__64->SetBinContent(24,0.03739042); LCTsigma_4__64->SetBinContent(25,0.03627509); LCTsigma_4__64->SetBinContent(26,0.03627509); LCTsigma_4__64->SetBinContent(27,0.03324774); LCTsigma_4__64->SetBinContent(28,0.03197306); LCTsigma_4__64->SetBinContent(29,0.03069839); LCTsigma_4__64->SetBinContent(30,0.02883949); LCTsigma_4__64->SetBinContent(31,0.02894571); LCTsigma_4__64->SetBinContent(32,0.02761793); LCTsigma_4__64->SetBinContent(33,0.02474991); LCTsigma_4__64->SetBinContent(34,0.02453747); LCTsigma_4__64->SetBinContent(35,0.0260777); LCTsigma_4__64->SetBinContent(36,0.02103211); LCTsigma_4__64->SetBinContent(37,0.02342213); LCTsigma_4__64->SetBinContent(38,0.02012922); LCTsigma_4__64->SetBinContent(39,0.01949188); LCTsigma_4__64->SetBinContent(40,0.01896077); LCTsigma_4__64->SetBinContent(41,0.0172612); LCTsigma_4__64->SetBinContent(42,0.01890766); LCTsigma_4__64->SetBinContent(43,0.01827032); LCTsigma_4__64->SetBinContent(44,0.01710187); LCTsigma_4__64->SetBinContent(45,0.01683631); LCTsigma_4__64->SetBinContent(46,0.01742054); LCTsigma_4__64->SetBinContent(47,0.01646453); LCTsigma_4__64->SetBinContent(48,0.01503053); LCTsigma_4__64->SetBinContent(49,0.01455252); LCTsigma_4__64->SetBinContent(50,0.01487119); LCTsigma_4__64->SetBinContent(51,0.0139683); LCTsigma_4__64->SetBinContent(52,0.01439319); LCTsigma_4__64->SetBinContent(53,0.01311852); LCTsigma_4__64->SetBinContent(54,0.01455252); LCTsigma_4__64->SetBinContent(55,0.01248118); LCTsigma_4__64->SetBinContent(56,0.0121094); LCTsigma_4__64->SetBinContent(57,0.0134903); LCTsigma_4__64->SetBinContent(58,0.01333096); LCTsigma_4__64->SetBinContent(59,0.01131273); LCTsigma_4__64->SetBinContent(60,0.01009117); LCTsigma_4__64->SetBinContent(61,0.01019739); LCTsigma_4__64->SetBinContent(62,0.01062228); LCTsigma_4__64->SetBinContent(63,0.01120651); LCTsigma_4__64->SetBinContent(64,0.01003805); LCTsigma_4__64->SetBinContent(65,0.009931832); LCTsigma_4__64->SetBinContent(66,0.01009117); LCTsigma_4__64->SetBinContent(67,0.01014428); LCTsigma_4__64->SetBinContent(68,0.009028938); LCTsigma_4__64->SetBinContent(69,0.009188272); LCTsigma_4__64->SetBinContent(70,0.008763381); LCTsigma_4__64->SetBinContent(71,0.009028938); LCTsigma_4__64->SetBinContent(72,0.00796671); LCTsigma_4__64->SetBinContent(73,0.007648041); LCTsigma_4__64->SetBinContent(74,0.007754264); LCTsigma_4__64->SetBinContent(75,0.008126044); LCTsigma_4__64->SetBinContent(76,0.008126044); LCTsigma_4__64->SetBinContent(77,0.008550935); LCTsigma_4__64->SetBinContent(78,0.007701153); LCTsigma_4__64->SetBinContent(79,0.00833849); LCTsigma_4__64->SetBinContent(80,0.008444712); LCTsigma_4__64->SetBinContent(81,0.007541819); LCTsigma_4__64->SetBinContent(82,0.007488707); LCTsigma_4__64->SetBinContent(83,0.006479591); LCTsigma_4__64->SetBinContent(84,0.006054699); LCTsigma_4__64->SetBinContent(85,0.006585813); LCTsigma_4__64->SetBinContent(86,0.006320256); LCTsigma_4__64->SetBinContent(87,0.005948477); LCTsigma_4__64->SetBinContent(88,0.005842254); LCTsigma_4__64->SetBinContent(89,0.005470474); LCTsigma_4__64->SetBinContent(90,0.005576697); LCTsigma_4__64->SetBinContent(91,0.006160922); LCTsigma_4__64->SetBinContent(92,0.005523585); LCTsigma_4__64->SetBinContent(93,0.006001588); LCTsigma_4__64->SetBinContent(94,0.006214034); LCTsigma_4__64->SetBinContent(95,0.005736031); LCTsigma_4__64->SetBinContent(96,0.00493936); LCTsigma_4__64->SetBinContent(97,0.004620692); LCTsigma_4__64->SetBinContent(98,0.004886249); LCTsigma_4__64->SetBinContent(99,0.00531114); LCTsigma_4__64->SetBinContent(100,0.005258028); LCTsigma_4__64->SetBinContent(101,0.4179867); LCTsigma_4__64->SetEntries(1890705); LCTsigma_4__64->SetStats(0); ci = TColor::GetColor("#ff0000"); LCTsigma_4__64->SetLineColor(ci); ci = TColor::GetColor("#ff0000"); LCTsigma_4__64->SetMarkerColor(ci); LCTsigma_4__64->GetXaxis()->SetTitle("cm"); LCTsigma_4__64->GetYaxis()->SetTitle("scaled number of entries"); LCTsigma_4__64->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("LCTsigma_1","ME11A: mean:2.4cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_2","ME11B: mean:2.1cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_3","ME12+13: mean:1.5cm;RMS:2.4cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_4","ME2: mean:1.4cm;RMS:2.2cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_5","ME3: mean:1.3cm;RMS:1.6cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_6","ME4: mean:1.3cm;RMS:1.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *LCTsigma_5__65 = new TH1D("LCTsigma_5__65","LCTsigma",100,0,40); LCTsigma_5__65->SetBinContent(1,2.360931); LCTsigma_5__65->SetBinContent(2,6.15692); LCTsigma_5__65->SetBinContent(3,68.89588); LCTsigma_5__65->SetBinContent(4,7.000274); LCTsigma_5__65->SetBinContent(5,5.379208); LCTsigma_5__65->SetBinContent(6,3.591525); LCTsigma_5__65->SetBinContent(7,2.210401); LCTsigma_5__65->SetBinContent(8,1.300472); LCTsigma_5__65->SetBinContent(9,0.7853251); LCTsigma_5__65->SetBinContent(10,0.4762223); LCTsigma_5__65->SetBinContent(11,0.3008438); LCTsigma_5__65->SetBinContent(12,0.2038183); LCTsigma_5__65->SetBinContent(13,0.155485); LCTsigma_5__65->SetBinContent(14,0.1113172); LCTsigma_5__65->SetBinContent(15,0.08804834); LCTsigma_5__65->SetBinContent(16,0.07706025); LCTsigma_5__65->SetBinContent(17,0.06657488); LCTsigma_5__65->SetBinContent(18,0.0543659); LCTsigma_5__65->SetBinContent(19,0.04675324); LCTsigma_5__65->SetBinContent(20,0.0400742); LCTsigma_5__65->SetBinContent(21,0.03777604); LCTsigma_5__65->SetBinContent(22,0.0343288); LCTsigma_5__65->SetBinContent(23,0.03224609); LCTsigma_5__65->SetBinContent(24,0.02930157); LCTsigma_5__65->SetBinContent(25,0.02556705); LCTsigma_5__65->SetBinContent(26,0.02420252); LCTsigma_5__65->SetBinContent(27,0.01989347); LCTsigma_5__65->SetBinContent(28,0.0216889); LCTsigma_5__65->SetBinContent(29,0.01824166); LCTsigma_5__65->SetBinContent(30,0.01831348); LCTsigma_5__65->SetBinContent(31,0.01522532); LCTsigma_5__65->SetBinContent(32,0.01500987); LCTsigma_5__65->SetBinContent(33,0.01386079); LCTsigma_5__65->SetBinContent(34,0.01601532); LCTsigma_5__65->SetBinContent(35,0.01421988); LCTsigma_5__65->SetBinContent(36,0.01292716); LCTsigma_5__65->SetBinContent(37,0.01278353); LCTsigma_5__65->SetBinContent(38,0.01364534); LCTsigma_5__65->SetBinContent(39,0.01235262); LCTsigma_5__65->SetBinContent(40,0.01041355); LCTsigma_5__65->SetBinContent(41,0.01070082); LCTsigma_5__65->SetBinContent(42,0.010629); LCTsigma_5__65->SetBinContent(43,0.01005446); LCTsigma_5__65->SetBinContent(44,0.009839007); LCTsigma_5__65->SetBinContent(45,0.01026991); LCTsigma_5__65->SetBinContent(46,0.008761743); LCTsigma_5__65->SetBinContent(47,0.00768448); LCTsigma_5__65->SetBinContent(48,0.007540844); LCTsigma_5__65->SetBinContent(49,0.006966304); LCTsigma_5__65->SetBinContent(50,0.008330838); LCTsigma_5__65->SetBinContent(51,0.007756297); LCTsigma_5__65->SetBinContent(52,0.007325392); LCTsigma_5__65->SetBinContent(53,0.007325392); LCTsigma_5__65->SetBinContent(54,0.007469027); LCTsigma_5__65->SetBinContent(55,0.006822669); LCTsigma_5__65->SetBinContent(56,0.006966304); LCTsigma_5__65->SetBinContent(57,0.007397209); LCTsigma_5__65->SetBinContent(58,0.00560177); LCTsigma_5__65->SetBinContent(59,0.005745405); LCTsigma_5__65->SetBinContent(60,0.00588904); LCTsigma_5__65->SetBinContent(61,0.005960858); LCTsigma_5__65->SetBinContent(62,0.006966304); LCTsigma_5__65->SetBinContent(63,0.004955412); LCTsigma_5__65->SetBinContent(64,0.006319946); LCTsigma_5__65->SetBinContent(65,0.005960858); LCTsigma_5__65->SetBinContent(66,0.006319946); LCTsigma_5__65->SetBinContent(67,0.003519061); LCTsigma_5__65->SetBinContent(68,0.004668142); LCTsigma_5__65->SetBinContent(69,0.003878149); LCTsigma_5__65->SetBinContent(70,0.003734513); LCTsigma_5__65->SetBinContent(71,0.003806331); LCTsigma_5__65->SetBinContent(72,0.004596324); LCTsigma_5__65->SetBinContent(73,0.003949966); LCTsigma_5__65->SetBinContent(74,0.004380872); LCTsigma_5__65->SetBinContent(75,0.004165419); LCTsigma_5__65->SetBinContent(76,0.004668142); LCTsigma_5__65->SetBinContent(77,0.003088155); LCTsigma_5__65->SetBinContent(78,0.003016338); LCTsigma_5__65->SetBinContent(79,0.003159973); LCTsigma_5__65->SetBinContent(80,0.003519061); LCTsigma_5__65->SetBinContent(81,0.003303608); LCTsigma_5__65->SetBinContent(82,0.003016338); LCTsigma_5__65->SetBinContent(83,0.00265725); LCTsigma_5__65->SetBinContent(84,0.004021784); LCTsigma_5__65->SetBinContent(85,0.003088155); LCTsigma_5__65->SetBinContent(86,0.003375426); LCTsigma_5__65->SetBinContent(87,0.002872703); LCTsigma_5__65->SetBinContent(88,0.002226345); LCTsigma_5__65->SetBinContent(89,0.002800885); LCTsigma_5__65->SetBinContent(90,0.002082709); LCTsigma_5__65->SetBinContent(91,0.002298162); LCTsigma_5__65->SetBinContent(92,0.00265725); LCTsigma_5__65->SetBinContent(93,0.002298162); LCTsigma_5__65->SetBinContent(94,0.001436351); LCTsigma_5__65->SetBinContent(95,0.002154527); LCTsigma_5__65->SetBinContent(96,0.00236998); LCTsigma_5__65->SetBinContent(97,0.00323179); LCTsigma_5__65->SetBinContent(98,0.001579986); LCTsigma_5__65->SetBinContent(99,0.002082709); LCTsigma_5__65->SetBinContent(100,0.001220899); LCTsigma_5__65->SetBinContent(101,0.1642468); LCTsigma_5__65->SetEntries(1394704); LCTsigma_5__65->SetStats(0); ci = TColor::GetColor("#00ff00"); LCTsigma_5__65->SetLineColor(ci); ci = TColor::GetColor("#00ff00"); LCTsigma_5__65->SetMarkerColor(ci); LCTsigma_5__65->GetXaxis()->SetTitle("cm"); LCTsigma_5__65->GetYaxis()->SetTitle("scaled number of entries"); LCTsigma_5__65->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("LCTsigma_1","ME11A: mean:2.4cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_2","ME11B: mean:2.1cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_3","ME12+13: mean:1.5cm;RMS:2.4cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_4","ME2: mean:1.4cm;RMS:2.2cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_5","ME3: mean:1.3cm;RMS:1.6cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_6","ME4: mean:1.3cm;RMS:1.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *LCTsigma_6__66 = new TH1D("LCTsigma_6__66","LCTsigma",100,0,40); LCTsigma_6__66->SetBinContent(1,2.735295); LCTsigma_6__66->SetBinContent(2,7.040362); LCTsigma_6__66->SetBinContent(3,65.03355); LCTsigma_6__66->SetBinContent(4,8.19953); LCTsigma_6__66->SetBinContent(5,6.22415); LCTsigma_6__66->SetBinContent(6,4.127459); LCTsigma_6__66->SetBinContent(7,2.484321); LCTsigma_6__66->SetBinContent(8,1.427667); LCTsigma_6__66->SetBinContent(9,0.797961); LCTsigma_6__66->SetBinContent(10,0.467717); LCTsigma_6__66->SetBinContent(11,0.2812113); LCTsigma_6__66->SetBinContent(12,0.1845988); LCTsigma_6__66->SetBinContent(13,0.1348398); LCTsigma_6__66->SetBinContent(14,0.1036042); LCTsigma_6__66->SetBinContent(15,0.08035906); LCTsigma_6__66->SetBinContent(16,0.06601247); LCTsigma_6__66->SetBinContent(17,0.05965639); LCTsigma_6__66->SetBinContent(18,0.04467419); LCTsigma_6__66->SetBinContent(19,0.04113294); LCTsigma_6__66->SetBinContent(20,0.03641128); LCTsigma_6__66->SetBinContent(21,0.02878398); LCTsigma_6__66->SetBinContent(22,0.02887478); LCTsigma_6__66->SetBinContent(23,0.02351751); LCTsigma_6__66->SetBinContent(24,0.02106588); LCTsigma_6__66->SetBinContent(25,0.01870505); LCTsigma_6__66->SetBinContent(26,0.01616261); LCTsigma_6__66->SetBinContent(27,0.01634422); LCTsigma_6__66->SetBinContent(28,0.01398339); LCTsigma_6__66->SetBinContent(29,0.01262137); LCTsigma_6__66->SetBinContent(30,0.01116855); LCTsigma_6__66->SetBinContent(31,0.009534126); LCTsigma_6__66->SetBinContent(32,0.006719289); LCTsigma_6__66->SetBinContent(33,0.01026054); LCTsigma_6__66->SetBinContent(34,0.009261723); LCTsigma_6__66->SetBinContent(35,0.007718102); LCTsigma_6__66->SetBinContent(36,0.007173295); LCTsigma_6__66->SetBinContent(37,0.007264096); LCTsigma_6__66->SetBinContent(38,0.007173295); LCTsigma_6__66->SetBinContent(39,0.005992879); LCTsigma_6__66->SetBinContent(40,0.005720476); LCTsigma_6__66->SetBinContent(41,0.004358458); LCTsigma_6__66->SetBinContent(42,0.005902078); LCTsigma_6__66->SetBinContent(43,0.005992879); LCTsigma_6__66->SetBinContent(44,0.006265283); LCTsigma_6__66->SetBinContent(45,0.005992879); LCTsigma_6__66->SetBinContent(46,0.005448072); LCTsigma_6__66->SetBinContent(47,0.003813651); LCTsigma_6__66->SetBinContent(48,0.004358458); LCTsigma_6__66->SetBinContent(49,0.003087241); LCTsigma_6__66->SetBinContent(50,0.004994066); LCTsigma_6__66->SetBinContent(51,0.005629675); LCTsigma_6__66->SetBinContent(52,0.004086054); LCTsigma_6__66->SetBinContent(53,0.002814837); LCTsigma_6__66->SetBinContent(54,0.003632048); LCTsigma_6__66->SetBinContent(55,0.003632048); LCTsigma_6__66->SetBinContent(56,0.003995253); LCTsigma_6__66->SetBinContent(57,0.004086054); LCTsigma_6__66->SetBinContent(58,0.00299644); LCTsigma_6__66->SetBinContent(59,0.003541247); LCTsigma_6__66->SetBinContent(60,0.003087241); LCTsigma_6__66->SetBinContent(61,0.003722849); LCTsigma_6__66->SetBinContent(62,0.003087241); LCTsigma_6__66->SetBinContent(63,0.002905638); LCTsigma_6__66->SetBinContent(64,0.002451632); LCTsigma_6__66->SetBinContent(65,0.00227003); LCTsigma_6__66->SetBinContent(66,0.002451632); LCTsigma_6__66->SetBinContent(67,0.002179229); LCTsigma_6__66->SetBinContent(68,0.002451632); LCTsigma_6__66->SetBinContent(69,0.002088428); LCTsigma_6__66->SetBinContent(70,0.002451632); LCTsigma_6__66->SetBinContent(71,0.002905638); LCTsigma_6__66->SetBinContent(72,0.002542434); LCTsigma_6__66->SetBinContent(73,0.001634422); LCTsigma_6__66->SetBinContent(74,0.001816024); LCTsigma_6__66->SetBinContent(75,0.00227003); LCTsigma_6__66->SetBinContent(76,0.002088428); LCTsigma_6__66->SetBinContent(77,0.00154362); LCTsigma_6__66->SetBinContent(78,0.001906825); LCTsigma_6__66->SetBinContent(79,0.001634422); LCTsigma_6__66->SetBinContent(80,0.001725223); LCTsigma_6__66->SetBinContent(81,0.001997626); LCTsigma_6__66->SetBinContent(82,0.001271217); LCTsigma_6__66->SetBinContent(83,0.001906825); LCTsigma_6__66->SetBinContent(84,0.001362018); LCTsigma_6__66->SetBinContent(85,0.00154362); LCTsigma_6__66->SetBinContent(86,0.000908012); LCTsigma_6__66->SetBinContent(87,0.001816024); LCTsigma_6__66->SetBinContent(88,0.001725223); LCTsigma_6__66->SetBinContent(89,0.0009988132); LCTsigma_6__66->SetBinContent(90,0.001816024); LCTsigma_6__66->SetBinContent(91,0.001089614); LCTsigma_6__66->SetBinContent(92,0.0009988132); LCTsigma_6__66->SetBinContent(93,0.001997626); LCTsigma_6__66->SetBinContent(94,0.000908012); LCTsigma_6__66->SetBinContent(95,0.0009988132); LCTsigma_6__66->SetBinContent(96,0.000908012); LCTsigma_6__66->SetBinContent(97,0.001180416); LCTsigma_6__66->SetBinContent(98,0.001089614); LCTsigma_6__66->SetBinContent(99,0.00154362); LCTsigma_6__66->SetBinContent(100,0.00154362); LCTsigma_6__66->SetBinContent(101,0.08925758); LCTsigma_6__66->SetEntries(1102290); LCTsigma_6__66->SetStats(0); ci = TColor::GetColor("#0000ff"); LCTsigma_6__66->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); LCTsigma_6__66->SetMarkerColor(ci); LCTsigma_6__66->GetXaxis()->SetTitle("cm"); LCTsigma_6__66->GetYaxis()->SetTitle("scaled number of entries"); LCTsigma_6__66->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("LCTsigma_1","ME11A: mean:2.4cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_2","ME11B: mean:2.1cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_3","ME12+13: mean:1.5cm;RMS:2.4cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_4","ME2: mean:1.4cm;RMS:2.2cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_5","ME3: mean:1.3cm;RMS:1.6cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("LCTsigma_6","ME4: mean:1.3cm;RMS:1.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TPaveText *pt = new TPaveText(0.01,0.9390678,0.2437097,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(1); pt->SetFillColor(0); TText *AText = pt->AddText("LCTsigma"); pt->Draw(); LCTsigma->Modified(); LCTsigma->cd(); LCTsigma->SetSelected(LCTsigma); }
void ptBestFit(float BIN_SIZE=5.0,bool BLIND=false,TString MASS,TString NAME) { gROOT->ProcessLine(".x ../../common/styleCMSTDR.C"); gSystem->Load("libHiggsAnalysisCombinedLimit.so"); gROOT->ForceStyle(); gStyle->SetOptStat(0); gStyle->SetOptTitle(0); gROOT->SetBatch(1); gStyle->SetPadRightMargin(0.04); gStyle->SetPadLeftMargin(0.16); gStyle->SetPadTopMargin(0.06); gStyle->SetPadBottomMargin(0.10); gStyle->SetTitleFont(42,"XY"); gStyle->SetTitleSize(0.0475,"XY"); gStyle->SetTitleOffset(0.9,"X"); gStyle->SetTitleOffset(1.5,"Y"); gStyle->SetLabelSize(0.0375,"XY"); RooMsgService::instance().setSilentMode(kTRUE); for(int i=0;i<2;i++) { RooMsgService::instance().setStreamStatus(i,kFALSE); } float XMIN = 80; float XMAX = 200; TFile *f1 = TFile::Open("datacards/datacard_m"+MASS+"_"+NAME+".root"); TFile *f2 = TFile::Open("combine/mlfit.vbfHbb_"+NAME+"_mH"+MASS+".root"); TFile *f3 = TFile::Open("root/sig_shapes_workspace_B80-200.root"); TFile *f4 = TFile::Open("root/data_shapes_workspace_"+NAME+".root"); RooWorkspace *w = (RooWorkspace*)f1->Get("w"); //w->Print(); RooAbsPdf *bkg_model = (RooAbsPdf*)w->pdf("model_s"); RooFitResult *res_s = (RooFitResult*)f2->Get("fit_s"); RooFitResult *res_b = (RooFitResult*)f2->Get("fit_b"); RooRealVar *rFit = dynamic_cast<RooRealVar *>(res_s->floatParsFinal()).find("r"); RooDataSet *data = (RooDataSet*)w->data("data_obs"); int nparS=0,nparB=0; cout << res_s->floatParsFinal().getSize() << endl; cout << res_b->floatParsFinal().getSize() << endl; nparS = res_s->floatParsFinal().getSize(); nparB = res_b->floatParsFinal().getSize(); float chi2sumS = 0.; float chi2sumB = 0.; int nparsum = 0; // if (BLIND) { // res_b->Print(); // } // else { // res_s->Print(); // } w->allVars().assignValueOnly(res_s->floatParsFinal()); // w->Print(); // w->allVars()->Print(); RooWorkspace *wSig = (RooWorkspace*)f3->Get("w"); RooWorkspace *wDat = (RooWorkspace*)f4->Get("w"); const RooSimultaneous *sim = dynamic_cast<const RooSimultaneous *> (bkg_model); const RooAbsCategoryLValue &cat = (RooAbsCategoryLValue &) sim->indexCat(); TList *datasets = data->split(cat,true); TIter next(datasets); //int count = 0; for(RooAbsData *ds = (RooAbsData*)next();ds != 0; ds = (RooAbsData*)next()) { //if (count > 0) return 0; //count++; RooAbsPdf *pdfi = sim->getPdf(ds->GetName()); RooArgSet *obs = (RooArgSet*)pdfi->getObservables(ds); RooRealVar *x = dynamic_cast<RooRealVar *>(obs->first()); RooRealVar *yield_vbf = (RooRealVar*)wSig->var("yield_signalVBF_mass"+MASS+"_"+TString(ds->GetName())); RooRealVar *yield_gf = (RooRealVar*)wSig->var("yield_signalGF_mass"+MASS+"_"+TString(ds->GetName())); TString ds_name(ds->GetName()); //----- get the QCD normalization ----------- RooRealVar *qcd_norm_final = dynamic_cast<RooRealVar *>(res_s->floatParsFinal()).find("CMS_vbfbb_qcd_norm_"+ds_name); RooRealVar *qcd_yield = (RooRealVar*)wDat->var("yield_data_"+ds_name); float Nqcd = exp(log(1.5)*qcd_norm_final->getVal())*qcd_yield->getVal(); float eNqcd = log(1.5)*qcd_norm_final->getError()*Nqcd; cout<<"QCD normalization = "<<Nqcd<<" +/- "<<eNqcd<<endl; TH1 *hCoarse = (TH1*)ds->createHistogram("coarseHisto_"+ds_name,*x); float norm = hCoarse->Integral(); int rebin = BIN_SIZE/hCoarse->GetBinWidth(1); hCoarse->Rebin(rebin); float MIN_VAL = TMath::Max(0.9*hCoarse->GetBinContent(hCoarse->GetMinimumBin()),1.0); float MAX_VAL = 1.3*hCoarse->GetBinContent(hCoarse->GetMaximumBin()); RooDataHist ds_coarse("ds_coarse_"+ds_name,"ds_coarse_"+ds_name,*x,hCoarse); TH1F *hBlind = (TH1F*)hCoarse->Clone("blindHisto_"+ds_name); for(int i=0;i<hBlind->GetNbinsX();i++) { double x0 = hBlind->GetBinCenter(i+1); if (x0 > 100 && x0 < 150) { hBlind->SetBinContent(i+1,0); hBlind->SetBinError(i+1,0); } } RooDataHist ds_blind("ds_blind_"+ds_name,"ds_blind_"+ds_name,*x,hBlind); RooHist *hresid,*hresid0; RooPlot *frame1 = x->frame(); RooPlot *frame2 = x->frame(); if (BLIND) { //cout << "Blind case: " << ds_coarse.GetName() << endl; ds_coarse.plotOn(frame1,LineColor(0),MarkerColor(0)); pdfi->plotOn(frame1,Components("shapeBkg_qcd_"+ds_name+",shapeBkg_top_"+ds_name+",shapeBkg_zjets_"+ds_name),VisualizeError(*res_s,1,kTRUE),FillColor(0),MoveToBack()); pdfi->plotOn(frame1,Components("shapeBkg_qcd_"+ds_name+",shapeBkg_top_"+ds_name+",shapeBkg_zjets_"+ds_name),LineWidth(2),LineStyle(3)); ds_blind.plotOn(frame1); hresid = frame1->residHist(); frame2->addPlotable(hresid,"pE1"); } else { //cout << "Non-blind case: " << ds_coarse.GetName() << endl; ds_coarse.plotOn(frame1); pdfi->plotOn(frame1); //cout << pdfi->getParameters(ds_coarse)->selectByAttrib("Constant",kFALSE)->getSize() << endl; cout<<"chi2/ndof (bkg+sig) = "<<frame1->chiSquare()<<endl; cout << ds_coarse.numEntries() << endl; chi2sumS += frame1->chiSquare()*ds_coarse.numEntries(); nparsum += ds_coarse.numEntries(); //hresid0 = frame1->residHist(); //pdfi->plotOn(frame1,VisualizeError(*res_s,1,kTRUE),FillColor(0),MoveToBack()); pdfi->plotOn(frame1,Components("shapeBkg_qcd_"+ds_name),LineWidth(2),LineStyle(5),LineColor(kGreen+2)); pdfi->plotOn(frame1,Components("shapeBkg_qcd_"+ds_name+",shapeBkg_top_"+ds_name+",shapeBkg_zjets_"+ds_name),LineWidth(2),LineStyle(2),LineColor(kBlack)); cout<<"chi2/ndof (bkg) = "<<frame1->chiSquare()<<endl; chi2sumB += frame1->chiSquare()*ds_coarse.numEntries(); pdfi->plotOn(frame1,Components("shapeBkg_qcd_"+ds_name+",shapeBkg_top_"+ds_name+",shapeBkg_zjets_"+ds_name),LineWidth(2),LineStyle(2),LineColor(kBlack),VisualizeError(*res_s,1,kTRUE),FillColor(0),MoveToBack()); hresid = frame1->residHist(); frame2->addPlotable(hresid,"pE1"); float yield_sig = rFit->getValV()*(yield_vbf->getValV()+yield_gf->getValV()); RooAbsPdf *signal_pdf = (RooAbsPdf*)w->pdf("shapeSig_qqH_"+ds_name); signal_pdf->plotOn(frame2,LineWidth(2),LineColor(kRed),Normalization(yield_sig,RooAbsReal::NumEvent),MoveToBack()); } // hresid0->Print(); // hresid->Print(); // double x2,y2; // for (int i=0; i<3; ++i) { // hresid0->GetPoint(i,x2,y2); // cout << "BKG+SIG\t" << x2 << "\t" << y2 << endl; // hresid->GetPoint(i,x2,y2); // cout << "BKG\t" << x2 << "\t" << y2 << endl; // ds_coarse.get(i); // cout << ds_coarse.weightError(RooAbsData::SumW2) << endl; // cout << endl; // } TCanvas* canFit = new TCanvas("Higgs_fit_"+ds_name,"Higgs_fit_"+ds_name,900,750); canFit->cd(1)->SetBottomMargin(0.4); frame1->SetMinimum(MIN_VAL); frame1->SetMaximum(MAX_VAL); frame1->GetYaxis()->SetNdivisions(510); frame1->GetXaxis()->SetTitleSize(0); frame1->GetXaxis()->SetLabelSize(0); frame1->GetYaxis()->SetTitle(TString::Format("Events / %1.1f GeV",BIN_SIZE)); frame1->Draw(); gPad->Update(); TList *list = (TList*)gPad->GetListOfPrimitives(); //list->Print(); TH1F *hUncH = new TH1F("hUncH"+ds_name,"hUncH"+ds_name,(XMAX-XMIN)/BIN_SIZE,XMIN,XMAX); TH1F *hUncL = new TH1F("hUncL"+ds_name,"hUncL"+ds_name,(XMAX-XMIN)/BIN_SIZE,XMIN,XMAX); TH1F *hUnc2H = new TH1F("hUnc2H"+ds_name,"hUnc2H"+ds_name,(XMAX-XMIN)/BIN_SIZE,XMIN,XMAX); TH1F *hUnc2L = new TH1F("hUnc2L"+ds_name,"hUnc2L"+ds_name,(XMAX-XMIN)/BIN_SIZE,XMIN,XMAX); TH1F *hUncC = new TH1F("hUncC"+ds_name,"hUncC"+ds_name,(XMAX-XMIN)/BIN_SIZE,XMIN,XMAX); RooCurve *errorBand,*gFit,*gQCDFit,*gBkgFit; //list->Print(); if (BLIND) { errorBand = (RooCurve*)list->FindObject("pdf_bin"+ds_name+"_Norm[mbbReg_"+ds_name+"]_errorband_Comp[shapeBkg_qcd_"+ds_name+",shapeBkg_top_"+ds_name+",shapeBkg_zjets_"+ds_name+"]"); gFit = (RooCurve*)list->FindObject("pdf_bin"+ds_name+"_Norm[mbbReg_"+ds_name+"]"+"_Comp[shapeBkg_qcd_"+ds_name+",shapeBkg_top_"+ds_name+",shapeBkg_zjets_"+ds_name+"]"); } else { //errorBand = (RooCurve*)list->FindObject("pdf_bin"+ds_name+"_Norm[mbbReg_"+ds_name+"]_errorband"); errorBand = (RooCurve*)list->FindObject("pdf_bin"+ds_name+"_Norm[mbbReg_"+ds_name+"]_errorband_Comp[shapeBkg_qcd_"+ds_name+",shapeBkg_top_"+ds_name+",shapeBkg_zjets_"+ds_name+"]"); gFit = (RooCurve*)list->FindObject("pdf_bin"+ds_name+"_Norm[mbbReg_"+ds_name+"]"); } gQCDFit = (RooCurve*)list->FindObject("pdf_bin"+ds_name+"_Norm[mbbReg_"+ds_name+"]"+"_Comp[shapeBkg_qcd_"+ds_name+"]"); gBkgFit = (RooCurve*)list->FindObject("pdf_bin"+ds_name+"_Norm[mbbReg_"+ds_name+"]"+"_Comp[shapeBkg_qcd_"+ds_name+",shapeBkg_top_"+ds_name+",shapeBkg_zjets_"+ds_name+"]"); for(int i=0;i<hUncH->GetNbinsX();i++) { double x0 = hUncH->GetBinCenter(i+1); double e1 = fabs(errorBand->Eval(x0)-gBkgFit->Eval(x0)); //double e1 = fabs(errorBand->Eval(x0)-gFit->Eval(x0)); double e2 = eNqcd/hUncH->GetNbinsX(); hUncH->SetBinContent(i+1,sqrt(pow(e2,2)+pow(e1,2))); hUnc2H->SetBinContent(i+1,2*sqrt(pow(e2,2)+pow(e1,2))); hUncL->SetBinContent(i+1,-sqrt(pow(e2,2)+pow(e1,2))); hUnc2L->SetBinContent(i+1,-2*sqrt(pow(e2,2)+pow(e1,2))); hUncC->SetBinContent(i+1,0.); } TPad* pad = new TPad("pad", "pad", 0., 0., 1., 1.); pad->SetTopMargin(0.63); pad->SetFillColor(0); pad->SetFillStyle(0); pad->Draw(); pad->cd(0); hUnc2H->GetXaxis()->SetTitle("m_{bb} (GeV)"); hUnc2H->GetYaxis()->SetTitle("Data - Bkg"); //hUnc2H->GetYaxis()->SetTitle("Data - Fit"); double YMAX = 1.1*frame2->GetMaximum(); double YMIN = -1.1*frame2->GetMaximum(); hUnc2H->GetYaxis()->SetRangeUser(YMIN,YMAX); hUnc2H->GetYaxis()->SetNdivisions(507); // hUnc2H->GetXaxis()->SetTitleOffset(0.9); // hUnc2H->GetYaxis()->SetTitleOffset(1.0); hUnc2H->GetYaxis()->SetTickLength(0.0); // hUnc2H->GetYaxis()->SetTitleSize(0.05); // hUnc2H->GetYaxis()->SetLabelSize(0.04); hUnc2H->GetYaxis()->CenterTitle(kTRUE); hUnc2H->SetFillColor(kGreen); hUnc2L->SetFillColor(kGreen); hUncH->SetFillColor(kYellow); hUncL->SetFillColor(kYellow); hUncC->SetLineColor(kBlack); hUncC->SetLineStyle(7); hUnc2H->Draw("HIST"); hUnc2L->Draw("same HIST"); hUncH->Draw("same HIST"); hUncL->Draw("same HIST"); hUncC->Draw("same HIST"); frame2->GetYaxis()->SetTickLength(0.03/0.4); frame2->Draw("same"); TList *list1 = (TList*)gPad->GetListOfPrimitives(); //list1->Print(); RooCurve *gSigFit = (RooCurve*)list1->FindObject("shapeSig_qqH_"+ds_name+"_Norm[mbbReg_"+ds_name+"]"); TLegend *leg = new TLegend(0.70,0.61,0.94,1.-gStyle->GetPadTopMargin()-0.01); leg->SetTextFont(42); leg->SetFillStyle(-1); //leg->SetHeader(ds_name+" (m_{H}="+MASS+")"); leg->SetHeader(TString::Format("Category %d",atoi(ds_name(3,1).Data())+1)); leg->AddEntry(hBlind,"Data","P"); if (!BLIND) { leg->AddEntry(gSigFit,"Fitted signal","L"); } TLine *gEmpty = new TLine(0.0,0.0,0.0,0.0); gEmpty->SetLineWidth(0); TLegendEntry *l1 = leg->AddEntry(gEmpty,"(m_{H} = "+MASS+" GeV)",""); l1->SetTextSize(0.038*0.97*0.85); leg->AddEntry(gFit,"Bkg. + signal","L"); leg->AddEntry(gBkgFit,"Bkg.","L"); leg->AddEntry(gQCDFit,"QCD","L"); leg->AddEntry(hUnc2H,"2#sigma bkg. unc.","F"); leg->AddEntry(hUncH,"1#sigma bkg. unc.","F"); leg->SetFillColor(0); leg->SetBorderSize(0); leg->SetTextFont(42); leg->SetTextSize(0.038*0.98); leg->Draw(); leg->SetY1(leg->GetY2()-leg->GetNRows()*0.045*0.96); TPaveText *paveCMS = new TPaveText(gStyle->GetPadLeftMargin()+0.02,0.7,gStyle->GetPadLeftMargin()+0.15,1.-gStyle->GetPadTopMargin()-0.01,"NDC"); paveCMS->SetTextFont(62); paveCMS->SetTextSize(gStyle->GetPadTopMargin()*3./4.); paveCMS->SetBorderSize(0); paveCMS->SetFillStyle(-1); paveCMS->SetTextAlign(12); paveCMS->AddText("CMS"); paveCMS->Draw(); gPad->Update(); paveCMS->SetY1NDC(paveCMS->GetY2NDC()-paveCMS->GetListOfLines()->GetSize()*gStyle->GetPadTopMargin()); TPaveText *paveLumi = new TPaveText(0.5,1.-gStyle->GetPadTopMargin(),0.98,1.00,"NDC"); paveLumi->SetTextFont(42); paveLumi->SetTextSize(gStyle->GetPadTopMargin()*3./4.); paveLumi->SetBorderSize(0); paveLumi->SetFillStyle(-1); paveLumi->SetTextAlign(32); paveLumi->AddText(TString::Format("%.1f fb^{-1} (8TeV)",(atoi(ds_name(3,1).Data())<4 ? 19.8 : 18.3)).Data());//+ 18.2 ; paveLumi->Draw(); TString path="."; //TString path="BiasV10_limit_BRN5p4_dX0p1_B80-200_CAT0-6/output/"; system(TString::Format("[ ! -d %s/plot ] && mkdir %s/plot",path.Data(),path.Data()).Data()); system(TString::Format("[ ! -d %s/plot/fits ] && mkdir %s/plot/fits",path.Data(),path.Data()).Data()); canFit->SaveAs(TString::Format("%s/plot/fits/Fit_mH%s_%s.pdf",path.Data(),MASS.Data(),ds_name.Data()).Data()); canFit->SaveAs(TString::Format("%s/plot/fits/Fit_mH%s_%s.png",path.Data(),MASS.Data(),ds_name.Data()).Data()); canFit->SaveAs(TString::Format("%s/plot/fits/Fit_mH%s_%s.eps",path.Data(),MASS.Data(),ds_name.Data()).Data()); TText *l = (TText*)paveCMS->AddText("Preliminary"); l->SetTextFont(52); paveCMS->Draw(); gPad->Update(); paveCMS->SetY1NDC(paveCMS->GetY2NDC()-paveCMS->GetListOfLines()->GetSize()*gStyle->GetPadTopMargin()); canFit->SaveAs(TString::Format("%s/plot/fits/Fit_mH%s_%s_prelim.pdf",path.Data(),MASS.Data(),ds_name.Data()).Data()); canFit->SaveAs(TString::Format("%s/plot/fits/Fit_mH%s_%s_prelim.png",path.Data(),MASS.Data(),ds_name.Data()).Data()); canFit->SaveAs(TString::Format("%s/plot/fits/Fit_mH%s_%s_prelim.eps",path.Data(),MASS.Data(),ds_name.Data()).Data()); delete ds; } cout << "chi2sumS: " << chi2sumS << endl; cout << "chi2sumB: " << chi2sumB << endl; cout << "nparS: " << nparS << endl; cout << "nparB: " << nparB << endl; cout << "nbinsum: " << nparsum << endl; cout << "chi2sumS/(nbinsum - nparS): " << chi2sumS / (float)(nparsum - nparS) << endl; cout << "chi2sumB/(nbinsum - nparB): " << chi2sumB / (float)(nparsum - nparB) << endl; delete datasets; }
//Assume heff_mct, htp, htpd, rat void getEff3Stats(TH1D* h1, TH1D* h2, TH1D* h3, TH1D* h4, bool isData, TString varType, TString INPUTDIR_PREFIX, double from, double to) { gStyle->SetOptTitle(0); gStyle->SetEndErrorSize(2); gStyle->SetErrorX(0.5); TLegend* leg = MakeLegend(); TPaveText* pt = MakeTPave(); TCanvas* c1 = new TCanvas("c1","c1",800,600); c1->cd(); if (varType != "rapidity") c1->SetLogx(); h1->SetMarkerSize(0); h1->SetLineWidth(1.2); //range if (varType == "pt") h1->GetXaxis()->SetRangeUser(8,180); else if (varType == "vtx") h1->GetXaxis()->SetRangeUser(0,20.4); else if (varType == "mass") h1->GetXaxis()->SetRangeUser(15, 999); h1->GetYaxis()->SetRangeUser(from,to); h1->GetXaxis()->SetMoreLogLabels(); h1->GetYaxis()->SetTitle("#epsilon"); h1->SetLineColor(kRed); h1->SetFillColor(kRed); h2->SetLineColor(kBlue); h2->SetFillColor(kBlue); h4->SetLineColor(kGreen); h4->SetFillColor(kGreen); h4->SetFillStyle(3144); //if you compare data to data h1->Draw("E2"); h1->GetXaxis()->SetTitle(getTitle(varType, true)); h2->Draw("E2same"); h4->Draw("E2same"); leg->AddEntry(h1,"MC Truth","f"); leg->AddEntry(h2,"MC T&P","f"); leg->AddEntry(h4,"Ratio","f"); leg->Draw("same"); //if (dataOnly && !(varType == "rrr")) pt->Draw("same"); //if (varType == "pt") c1->SetLogx(); gROOT->ProcessLine(".L ../tools/stattools.C"); //Make TPave ostringstream tmpstrm1; ostringstream tmpstrm2; ostringstream tmpstrm3; tmpstrm3 << INPUTDIR_PREFIX << " " << h1->GetName(); tmpstrm1 << estimatorPerMassHisto1(h2,h3); tmpstrm2 << estimatorPerMassHisto2(h2,h3,h1); TPaveText *pt = new TPaveText(0.25,0.77,0.40,0.92,"brNDC"); pt->SetFillColor(0); // pt->SetTextFont(72); pt->SetTextSize(0.040); pt->SetBorderSize(0); pt->SetTextAlign(12); pt->AddText(TString(tmpstrm3.str().c_str())); pt->AddText("Simple estimator: "+TString(tmpstrm1.str().c_str())); pt->AddText("Combined estimator: "+TString(tmpstrm2.str().c_str())); pt->Draw("same"); //Save c1->SaveAs(INPUTDIR_PREFIX+"/stats"+h1->GetName()+varType+".png"); }
void bdt_in_regions(void){ TFile *contfile = TFile::Open("/home/vitaly/B0toDh0/TMVA/FIL_b2dh_cont.root"); TTree *conttree = (TTree*)contfile->Get("TEvent"); TFile *sigfile = TFile::Open("/home/vitaly/B0toDh0/TMVA/FIL_b2dh_sigPi0.root"); TTree *sigtree = (TTree*)sigfile->Get("TEvent"); const bool save_flag = false; RooArgSet argset; RooCategory b0f("b0f","b0f"); b0f.defineType("comb",-1); b0f.defineType("sig",1); b0f.defineType("badpi",5); b0f.defineType("fsr",10); argset.add(b0f); const double mbcMin = 5.20; const double mbcMax = 5.29; const double deMin = -0.3; const double deMax = 0.3; RooRealVar mbc("mbc","M_{bc}",mbcMin,mbcMax,"GeV"); argset.add(mbc); // mbc.setRange("Signal",mbc_min,mbc_max); // mbc.setRange("mbcSignal",mbc_min,mbc_max); // mbc.setRange("deSignal",mbcMin,mbcMax); RooRealVar de("de","#DeltaE",deMin,deMax,"GeV"); argset.add(de); // de.setRange("Signal",de_min,de_max); // de.setRange("mbcSignal",deMin,deMax); // de.setRange("deSignal",de_min,de_max); RooRealVar bdtgsl("bdtgsl","bdtgsl",-1.,1.); argset.add(bdtgsl); bdtgsl.setRange("Cut",bdtgsl_cut,1.); RooRealVar bdtgfr("bdtgfr","bdtgfr",-1.,1.); argset.add(bdtgfr); bdtgfr.setRange("Cut",bdtgfr_cut,1.); RooDataSet sigds("sigds","sigds",sigtree,argset,"mbc>0||mbc<=0 && b0f != -1"); sigds.Print(); RooDataSet contds("contds","contds",conttree,argset,"mbc>0||mbc<=0 && b0f == -1"); contds.Print(); stringstream out; ///////////////// // BDTG Signal // ///////////////// // soft cut // out.str(""); out << "mbc>" << mbc_min << " && mbc<" << mbc_max << " && de>" << de_min << " && de<" << de_max; RooDataSet* dssl_s_sig = sigds.reduce(RooArgSet(bdtgsl),out.str().c_str()); RooDataHist* dhsl_s_sig = dssl_s_sig->binnedClone(); RooHistPdf* hslpdf_s_sig = new RooHistPdf("hslpdf_s_sig","hslpdf_s_sig",RooArgSet(bdtgsl),*dhsl_s_sig); const double sl_eff_s = 100*hslpdf_s_sig->createIntegral(RooArgSet(bdtgsl),NormSet(RooArgSet(bdtgsl)),Range("Cut"))->getVal(); // delete dhsl_s_sig; // delete dssl_s_sig; RooDataSet* dsfr_s_sig = sigds.reduce(RooArgSet(bdtgfr),out.str().c_str()); RooDataHist* dhfr_s_sig = dsfr_s_sig->binnedClone(); RooHistPdf* hfrpdf_s_sig = new RooHistPdf("hfrpdf_s_sig","hfrpdf_s_sig",RooArgSet(bdtgfr),*dhfr_s_sig); const double fr_eff_s = 100*hfrpdf_s_sig->createIntegral(RooArgSet(bdtgfr),NormSet(RooArgSet(bdtgfr)),Range("Cut"))->getVal(); // delete dhfr_s_sig; // delete dsfr_s_sig; // soft cut // out.str(""); out << "mbc<5.289 && mbc>5.250 && de<0.1 && de>-0.1"; RooDataSet* dssl_side_sig = sigds.reduce(RooArgSet(bdtgsl),out.str().c_str()); RooDataHist* dhsl_side_sig = dssl_side_sig->binnedClone(); RooHistPdf* hslpdf_side_sig = new RooHistPdf("hslpdf_side_sig","hslpdf_side_sig",RooArgSet(bdtgsl),*dhsl_side_sig); const double sl_eff_sl = 100*hslpdf_side_sig->createIntegral(RooArgSet(bdtgsl),NormSet(RooArgSet(bdtgsl)),Range("Cut"))->getVal(); // delete dhsl_side_sig; // delete dssl_side_sig; RooDataSet* dsfr_side_sig = sigds.reduce(RooArgSet(bdtgfr),out.str().c_str()); RooDataHist* dhfr_side_sig = dsfr_side_sig->binnedClone(); RooHistPdf* hfrpdf_side_sig = new RooHistPdf("hfrpdf_side_sig","hfrpdf_side_sig",RooArgSet(bdtgfr),*dhfr_side_sig); const double fr_eff_sl = 100*hfrpdf_side_sig->createIntegral(RooArgSet(bdtgfr),NormSet(RooArgSet(bdtgfr)),Range("Cut"))->getVal(); // delete dhfr_side_sig; // delete dsfr_side_sig; // full range // out.str(""); RooDataSet* dssl_full_sig = sigds.reduce(RooArgSet(bdtgsl),out.str().c_str()); RooDataHist* dhsl_full_sig = dssl_full_sig->binnedClone(); RooHistPdf* hslpdf_full_sig = new RooHistPdf("hslpdf_full_sig","hslpdf_full_sig",RooArgSet(bdtgsl),*dhsl_full_sig); const double sl_eff_fr = 100*hslpdf_full_sig->createIntegral(RooArgSet(bdtgsl),NormSet(RooArgSet(bdtgsl)),Range("Cut"))->getVal(); // delete dhsl_full_sig; // delete dssl_full_sig; RooDataSet* dsfr_full_sig = sigds.reduce(RooArgSet(bdtgfr),out.str().c_str()); RooDataHist* dhfr_full_sig = dsfr_full_sig->binnedClone(); RooHistPdf* hfrpdf_full_sig = new RooHistPdf("hfrpdf_full_sig","hfrpdf_full_sig",RooArgSet(bdtgfr),*dhfr_full_sig); const double fr_eff_fr = 100*hfrpdf_full_sig->createIntegral(RooArgSet(bdtgfr),NormSet(RooArgSet(bdtgfr)),Range("Cut"))->getVal(); // delete dhfr_full_sig; // delete dsfr_full_sig; //////////////////// // BDTG Continuum // //////////////////// // soft cut // out.str(""); out << "mbc>" << mbc_min << " && mbc<" << mbc_max << " && de>" << de_min << " && de<" << de_max; RooDataSet* dssl_s_cont = contds.reduce(RooArgSet(bdtgsl),out.str().c_str()); RooDataHist* dhsl_s_cont = dssl_s_cont->binnedClone(); RooHistPdf* hslpdf_s_cont = new RooHistPdf("hslpdf_s_cont","hslpdf_s_cont",RooArgSet(bdtgsl),*dhsl_s_cont); const double sl_reg_s = 100*(1-hslpdf_s_cont->createIntegral(RooArgSet(bdtgsl),NormSet(RooArgSet(bdtgsl)),Range("Cut"))->getVal()); // delete dhsl_s_cont; // delete dssl_s_cont; RooDataSet* dsfr_s_cont = contds.reduce(RooArgSet(bdtgfr),out.str().c_str()); RooDataHist* dhfr_s_cont = dsfr_s_cont->binnedClone(); RooHistPdf* hfrpdf_s_cont = new RooHistPdf("hfrpdf_s_cont","hfrpdf_s_cont",RooArgSet(bdtgfr),*dhfr_s_cont); const double fr_reg_s = 100*(1-hfrpdf_s_cont->createIntegral(RooArgSet(bdtgfr),NormSet(RooArgSet(bdtgfr)),Range("Cut"))->getVal()); // delete dhfr_s_cont; // delete dsfr_s_cont; // soft cut // out.str(""); out << "mbc<5.289 && mbc>5.250 && de<0.1 && de>-0.1"; RooDataSet* dssl_side_cont = contds.reduce(RooArgSet(bdtgsl),out.str().c_str()); RooDataHist* dhsl_side_cont = dssl_side_cont->binnedClone(); RooHistPdf* hslpdf_side_cont = new RooHistPdf("hslpdf_side_cont","hslpdf_side_cont",RooArgSet(bdtgsl),*dhsl_side_cont); const double sl_reg_sl = 100*(1-hslpdf_side_cont->createIntegral(RooArgSet(bdtgsl),NormSet(RooArgSet(bdtgsl)),Range("Cut"))->getVal()); // delete dhsl_side_cont; // delete dssl_side_cont; RooDataSet* dsfr_side_cont = contds.reduce(RooArgSet(bdtgfr),out.str().c_str()); RooDataHist* dhfr_side_cont = dsfr_side_cont->binnedClone(); RooHistPdf* hfrpdf_side_cont = new RooHistPdf("hfrpdf_side_cont","hfrpdf_side_cont",RooArgSet(bdtgfr),*dhfr_side_cont); const double fr_reg_sl = 100*(1-hfrpdf_side_cont->createIntegral(RooArgSet(bdtgfr),NormSet(RooArgSet(bdtgfr)),Range("Cut"))->getVal()); // delete dhfr_side_cont; // delete dsfr_side_cont; // full range // out.str(""); RooDataSet* dssl_full_cont = contds.reduce(RooArgSet(bdtgsl),out.str().c_str()); RooDataHist* dhsl_full_cont = dssl_full_cont->binnedClone(); RooHistPdf* hslpdf_full_cont = new RooHistPdf("hslpdf_full_cont","hslpdf_full_cont",RooArgSet(bdtgsl),*dhsl_full_cont); const double sl_reg_fr = 100*(1-hslpdf_full_cont->createIntegral(RooArgSet(bdtgsl),NormSet(RooArgSet(bdtgsl)),Range("Cut"))->getVal()); // delete dhsl_full_cont; // delete dssl_full_cont; RooDataSet* dsfr_full_cont = contds.reduce(RooArgSet(bdtgfr),out.str().c_str()); RooDataHist* dhfr_full_cont = dsfr_full_cont->binnedClone(); RooHistPdf* hfrpdf_full_cont = new RooHistPdf("hfrpdf_full_cont","hfrpdf_full_cont",RooArgSet(bdtgfr),*dhfr_full_cont); const double fr_reg_fr = 100*(1-hfrpdf_full_cont->createIntegral(RooArgSet(bdtgfr),NormSet(RooArgSet(bdtgfr)),Range("Cut"))->getVal()); // delete dhfr_full_cont; // delete dsfr_full_cont; /////////// // Plots // /////////// // signal sl // RooPlot* bdtgSigslFrame = bdtgsl.frame(); hslpdf_s_sig->plotOn(bdtgSigslFrame,LineWidth(2),LineColor(kRed)); hslpdf_side_sig->plotOn(bdtgSigslFrame,LineWidth(2)); hslpdf_full_sig->plotOn(bdtgSigslFrame,LineWidth(2),LineColor(kBlack)); TCanvas* cbdtgs_sl = new TCanvas("bdtgs_sl","BDTg signal soft cut",700,500); cbdtgs_sl->cd(); TPad *pad1 = new TPad("pad1","pad1",0.01,0.01,0.99,0.99); pad1->Draw(); pad1->cd(); pad1->SetLeftMargin(0.15); pad1->SetFillColor(0); pad1->SetLogy(); bdtgSigslFrame->GetXaxis()->SetTitleSize(0.05); bdtgSigslFrame->GetXaxis()->SetTitleOffset(0.85); bdtgSigslFrame->GetXaxis()->SetLabelSize(0.04); bdtgSigslFrame->GetYaxis()->SetTitleOffset(1.6); bdtgSigslFrame->Draw(); out << setprecision(4); TPaveText *pt = new TPaveText(0.4,0.84,0.6,0.91,"brNDC"); pt->SetFillColor(0); pt->SetTextAlign(12); out.str(""); out << "SR: " << sl_eff_s; pt->AddText(out.str().c_str()); pt->SetTextColor(kRed); pt->Draw(); TPaveText *pt2 = new TPaveText(0.4,0.77,0.6,0.84,"brNDC"); pt2->SetFillColor(0); pt2->SetTextAlign(12); out.str(""); out << "SC: " << sl_eff_sl; pt2->AddText(out.str().c_str()); pt2->SetTextColor(kBlue); pt2->Draw(); TPaveText *pt3 = new TPaveText(0.4,0.70,0.6,0.77,"brNDC"); pt3->SetFillColor(0); pt3->SetTextAlign(12); out.str(""); out << "FR: " << sl_eff_fr; pt3->AddText(out.str().c_str()); pt3->SetTextColor(kBlack); pt3->Draw(); TLine *line_s = new TLine(bdtgsl_cut,0,bdtgsl_cut,0.1); line_s->SetLineColor(kBlue); line_s->SetLineStyle(1); line_s->SetLineWidth((Width_t)2.); line_s->Draw(); if(save_flag) cbdtgs_sl->Print("../Reports/pics/bdtg_diff_sl_sig.png"); // signal fr // RooPlot* bdtgSigfrFrame = bdtgfr.frame(); hfrpdf_s_sig->plotOn(bdtgSigfrFrame,LineWidth(2),LineColor(kRed)); hfrpdf_side_sig->plotOn(bdtgSigfrFrame,LineWidth(2)); hfrpdf_full_sig->plotOn(bdtgSigfrFrame,LineWidth(2),LineColor(kBlack)); TCanvas* cbdtgs_fr = new TCanvas("bdtgs_fr","BDTg signal full range",700,500); cbdtgs_fr->cd(); TPad *pad1 = new TPad("pad1","pad1",0.01,0.01,0.99,0.99); pad1->Draw(); pad1->cd(); pad1->SetLeftMargin(0.15); pad1->SetFillColor(0); pad1->SetLogy(); bdtgSigfrFrame->GetXaxis()->SetTitleSize(0.05); bdtgSigfrFrame->GetXaxis()->SetTitleOffset(0.85); bdtgSigfrFrame->GetXaxis()->SetLabelSize(0.04); bdtgSigfrFrame->GetYaxis()->SetTitleOffset(1.6); bdtgSigfrFrame->Draw(); TPaveText *pt = new TPaveText(0.4,0.84,0.6,0.91,"brNDC"); pt->SetFillColor(0); pt->SetTextAlign(12); out.str(""); out << "SR: " << fr_eff_s; pt->AddText(out.str().c_str()); pt->SetTextColor(kRed); pt->Draw(); TPaveText *pt2 = new TPaveText(0.4,0.77,0.6,0.84,"brNDC"); pt2->SetFillColor(0); pt2->SetTextAlign(12); out.str(""); out << "SC: " << fr_eff_sl; pt2->AddText(out.str().c_str()); pt2->SetTextColor(kBlue); pt2->Draw(); TPaveText *pt3 = new TPaveText(0.4,0.70,0.6,0.77,"brNDC"); pt3->SetFillColor(0); pt3->SetTextAlign(12); out.str(""); out << "FR: " << fr_eff_fr; pt3->AddText(out.str().c_str()); pt3->SetTextColor(kBlack); pt3->Draw(); TLine *line_s = new TLine(bdtgfr_cut,0,bdtgfr_cut,0.04); line_s->SetLineColor(kBlue); line_s->SetLineStyle(1); line_s->SetLineWidth((Width_t)2.); line_s->Draw(); if(save_flag) cbdtgs_fr->Print("../Reports/pics/bdtg_diff_fr_sig.png"); // continuum sl // RooPlot* bdtgContslFrame = bdtgsl.frame(); hslpdf_s_cont->plotOn(bdtgContslFrame,LineWidth(2),LineColor(kRed)); hslpdf_side_cont->plotOn(bdtgContslFrame,LineWidth(2)); hslpdf_full_cont->plotOn(bdtgContslFrame,LineWidth(2),LineColor(kBlack)); TCanvas* cbdtgc_sl = new TCanvas("cbdtgc_sl","BDTg continuum soft cut",700,500); cbdtgc_sl->cd(); TPad *pad1 = new TPad("pad1","pad1",0.01,0.01,0.99,0.99); pad1->Draw(); pad1->cd(); pad1->SetLeftMargin(0.15); pad1->SetFillColor(0); pad1->SetLogy(); bdtgContslFrame->GetXaxis()->SetTitleSize(0.05); bdtgContslFrame->GetXaxis()->SetTitleOffset(0.85); bdtgContslFrame->GetXaxis()->SetLabelSize(0.04); bdtgContslFrame->GetYaxis()->SetTitleOffset(1.6); bdtgContslFrame->Draw(); TPaveText *pt = new TPaveText(0.4,0.84,0.6,0.91,"brNDC"); pt->SetFillColor(0); pt->SetTextAlign(12); out.str(""); out << "SR: " << sl_reg_s; pt->AddText(out.str().c_str()); pt->SetTextColor(kRed); pt->Draw(); TPaveText *pt2 = new TPaveText(0.4,0.77,0.6,0.84,"brNDC"); pt2->SetFillColor(0); pt2->SetTextAlign(12); out.str(""); out << "SC: " << sl_reg_sl; pt2->AddText(out.str().c_str()); pt2->SetTextColor(kBlue); pt2->Draw(); TPaveText *pt3 = new TPaveText(0.4,0.70,0.6,0.77,"brNDC"); pt3->SetFillColor(0); pt3->SetTextAlign(12); out.str(""); out << "FR: " << sl_reg_fr; pt3->AddText(out.str().c_str()); pt3->SetTextColor(kBlack); pt3->Draw(); TLine *line_s = new TLine(bdtgsl_cut,0,bdtgsl_cut,0.04); line_s->SetLineColor(kBlue); line_s->SetLineStyle(1); line_s->SetLineWidth((Width_t)2.); line_s->Draw(); if(save_flag) cbdtgc_sl->Print("../Reports/pics/bdtg_diff_sl_cont.png"); // continuum fr // RooPlot* bdtgContfrFrame = bdtgfr.frame(); hfrpdf_s_cont->plotOn(bdtgContfrFrame,LineWidth(2),LineColor(kRed)); hfrpdf_side_cont->plotOn(bdtgContfrFrame,LineWidth(2)); hfrpdf_full_cont->plotOn(bdtgContfrFrame,LineWidth(2),LineColor(kBlack)); TCanvas* cbdtgc_fr = new TCanvas("cbdtgc_fr","BDTg continuum full region",700,500); cbdtgc_fr->cd(); TPad *pad1 = new TPad("pad1","pad1",0.01,0.01,0.99,0.99); pad1->Draw(); pad1->cd(); pad1->SetLeftMargin(0.15); pad1->SetFillColor(0); pad1->SetLogy(); bdtgContfrFrame->GetXaxis()->SetTitleSize(0.05); bdtgContfrFrame->GetXaxis()->SetTitleOffset(0.85); bdtgContfrFrame->GetXaxis()->SetLabelSize(0.04); bdtgContfrFrame->GetYaxis()->SetTitleOffset(1.6); bdtgContfrFrame->Draw(); TPaveText *pt = new TPaveText(0.4,0.84,0.6,0.91,"brNDC"); pt->SetFillColor(0); pt->SetTextAlign(12); out.str(""); out << "SR: " << fr_reg_s; pt->AddText(out.str().c_str()); pt->SetTextColor(kRed); pt->Draw(); TPaveText *pt2 = new TPaveText(0.4,0.77,0.6,0.84,"brNDC"); pt2->SetFillColor(0); pt2->SetTextAlign(12); out.str(""); out << "SC: " << fr_reg_sl; pt2->AddText(out.str().c_str()); pt2->SetTextColor(kBlue); pt2->Draw(); TPaveText *pt3 = new TPaveText(0.4,0.70,0.6,0.77,"brNDC"); pt3->SetFillColor(0); pt3->SetTextAlign(12); out.str(""); out << "FR: " << fr_reg_fr; pt3->AddText(out.str().c_str()); pt3->SetTextColor(kBlack); pt3->Draw(); TLine *line_s = new TLine(bdtgfr_cut,0,bdtgfr_cut,0.1); line_s->SetLineColor(kBlue); line_s->SetLineStyle(1); line_s->SetLineWidth((Width_t)2.); line_s->Draw(); if(save_flag) cbdtgc_fr->Print("../Reports/pics/bdtg_diff_fr_cont.png"); return; }
void METJets() { //=========Macro generated from canvas: METJets/METJets //========= (Mon Nov 23 11:05:00 2015) by ROOT version6.02/05 TCanvas *METJets = new TCanvas("METJets", "METJets",100,122,700,700); METJets->Range(-1.875,-6.772831,16.875,5.054722); METJets->SetFillColor(0); METJets->SetBorderMode(0); METJets->SetBorderSize(2); METJets->SetLogy(); METJets->SetFrameBorderMode(0); METJets->SetFrameBorderMode(0); THStack *METJets = new THStack(); METJets->SetName("METJets"); METJets->SetTitle("METJets"); TH1F *METJets_stack_6 = new TH1F("METJets_stack_6","METJets",15,0,15); METJets_stack_6->SetMinimum(2.569948e-06); METJets_stack_6->SetMaximum(7446.75); METJets_stack_6->SetDirectory(0); METJets_stack_6->SetStats(0); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#000099"); METJets_stack_6->SetLineColor(ci); METJets_stack_6->GetXaxis()->SetTitle("METJets"); METJets_stack_6->GetXaxis()->SetLabelFont(42); METJets_stack_6->GetXaxis()->SetLabelSize(0.035); METJets_stack_6->GetXaxis()->SetTitleSize(0.035); METJets_stack_6->GetXaxis()->SetTitleFont(42); METJets_stack_6->GetYaxis()->SetTitle("Events/pb"); METJets_stack_6->GetYaxis()->SetLabelFont(42); METJets_stack_6->GetYaxis()->SetLabelSize(0.035); METJets_stack_6->GetYaxis()->SetTitleSize(0.035); METJets_stack_6->GetYaxis()->SetTitleFont(42); METJets_stack_6->GetZaxis()->SetLabelFont(42); METJets_stack_6->GetZaxis()->SetLabelSize(0.035); METJets_stack_6->GetZaxis()->SetTitleSize(0.035); METJets_stack_6->GetZaxis()->SetTitleFont(42); METJets->SetHistogram(METJets_stack_6); TH1D *METJets26 = new TH1D("METJets26"," Number of jets in MET hemisphere",15,0,15); METJets26->SetBinContent(1,2.358311); METJets26->SetBinContent(2,1799.25); METJets26->SetBinContent(3,2794.573); METJets26->SetBinContent(4,982.1805); METJets26->SetBinContent(5,126.0732); METJets26->SetBinContent(6,6.831502); METJets26->SetBinContent(7,0.05059331); METJets26->SetBinError(1,0.8851475); METJets26->SetBinError(2,24.25261); METJets26->SetBinError(3,30.24717); METJets26->SetBinError(4,17.9355); METJets26->SetBinError(5,6.393654); METJets26->SetBinError(6,1.459512); METJets26->SetBinError(7,0.02038811); METJets26->SetEntries(35032); ci = TColor::GetColor("#00cc00"); METJets26->SetFillColor(ci); ci = TColor::GetColor("#00cc00"); METJets26->SetLineColor(ci); ci = TColor::GetColor("#00cc00"); METJets26->SetMarkerColor(ci); METJets26->SetMarkerStyle(22); METJets26->GetXaxis()->SetTitle("METJets"); METJets26->GetXaxis()->SetLabelFont(42); METJets26->GetXaxis()->SetLabelSize(0.035); METJets26->GetXaxis()->SetTitleSize(0.035); METJets26->GetXaxis()->SetTitleFont(42); METJets26->GetYaxis()->SetTitle("Events/pb"); METJets26->GetYaxis()->SetLabelFont(42); METJets26->GetYaxis()->SetLabelSize(0.035); METJets26->GetYaxis()->SetTitleSize(0.035); METJets26->GetYaxis()->SetTitleFont(42); METJets26->GetZaxis()->SetLabelFont(42); METJets26->GetZaxis()->SetLabelSize(0.035); METJets26->GetZaxis()->SetTitleSize(0.035); METJets26->GetZaxis()->SetTitleFont(42); METJets->Add(METJets,""); TH1D *METJets27 = new TH1D("METJets27"," Number of jets in MET hemisphere",15,0,15); METJets27->SetBinContent(1,0.8785647); METJets27->SetBinContent(2,19.65506); METJets27->SetBinContent(3,13.48662); METJets27->SetBinContent(4,1.798839); METJets27->SetBinContent(5,0.132607); METJets27->SetBinContent(6,0.006526677); METJets27->SetBinContent(7,0.0001605133); METJets27->SetBinContent(8,1.473949e-05); METJets27->SetBinError(1,0.02795641); METJets27->SetBinError(2,0.1254575); METJets27->SetBinError(3,0.1000964); METJets27->SetBinError(4,0.03249664); METJets27->SetBinError(5,0.007171238); METJets27->SetBinError(6,0.001513783); METJets27->SetBinError(7,4.840768e-05); METJets27->SetBinError(8,1.473949e-05); METJets27->SetEntries(136801); ci = TColor::GetColor("#00ffff"); METJets27->SetFillColor(ci); ci = TColor::GetColor("#00ffff"); METJets27->SetLineColor(ci); ci = TColor::GetColor("#00ffff"); METJets27->SetMarkerColor(ci); METJets27->SetMarkerStyle(20); METJets27->GetXaxis()->SetTitle("METJets"); METJets27->GetXaxis()->SetLabelFont(42); METJets27->GetXaxis()->SetLabelSize(0.035); METJets27->GetXaxis()->SetTitleSize(0.035); METJets27->GetXaxis()->SetTitleFont(42); METJets27->GetYaxis()->SetTitle("Events/pb"); METJets27->GetYaxis()->SetLabelFont(42); METJets27->GetYaxis()->SetLabelSize(0.035); METJets27->GetYaxis()->SetTitleSize(0.035); METJets27->GetYaxis()->SetTitleFont(42); METJets27->GetZaxis()->SetLabelFont(42); METJets27->GetZaxis()->SetLabelSize(0.035); METJets27->GetZaxis()->SetTitleSize(0.035); METJets27->GetZaxis()->SetTitleFont(42); METJets->Add(METJets,""); TH1D *METJets28 = new TH1D("METJets28"," Number of jets in MET hemisphere",15,0,15); METJets28->SetBinContent(1,0.1431715); METJets28->SetBinContent(2,2.860636); METJets28->SetBinContent(3,1.738326); METJets28->SetBinContent(4,0.1855333); METJets28->SetBinContent(5,0.01162161); METJets28->SetBinContent(6,0.0007176836); METJets28->SetBinContent(7,3.39293e-05); METJets28->SetBinError(1,0.003525434); METJets28->SetBinError(2,0.01498037); METJets28->SetBinError(3,0.0112588); METJets28->SetBinError(4,0.003217574); METJets28->SetBinError(5,0.0006944844); METJets28->SetBinError(6,0.0001304861); METJets28->SetBinError(7,2.841073e-05); METJets28->SetEntries(131338); ci = TColor::GetColor("#ffcc00"); METJets28->SetFillColor(ci); ci = TColor::GetColor("#ffcc00"); METJets28->SetLineColor(ci); ci = TColor::GetColor("#ffcc00"); METJets28->SetMarkerColor(ci); METJets28->SetMarkerStyle(21); METJets28->GetXaxis()->SetTitle("METJets"); METJets28->GetXaxis()->SetLabelFont(42); METJets28->GetXaxis()->SetLabelSize(0.035); METJets28->GetXaxis()->SetTitleSize(0.035); METJets28->GetXaxis()->SetTitleFont(42); METJets28->GetYaxis()->SetTitle("Events/pb"); METJets28->GetYaxis()->SetLabelFont(42); METJets28->GetYaxis()->SetLabelSize(0.035); METJets28->GetYaxis()->SetTitleSize(0.035); METJets28->GetYaxis()->SetTitleFont(42); METJets28->GetZaxis()->SetLabelFont(42); METJets28->GetZaxis()->SetLabelSize(0.035); METJets28->GetZaxis()->SetTitleSize(0.035); METJets28->GetZaxis()->SetTitleFont(42); METJets->Add(METJets,""); TH1D *METJets29 = new TH1D("METJets29"," Number of jets in MET hemisphere",15,0,15); METJets29->SetBinContent(1,0.003208312); METJets29->SetBinContent(2,0.03535313); METJets29->SetBinContent(3,0.02142474); METJets29->SetBinContent(4,0.003779021); METJets29->SetBinContent(5,0.0003701898); METJets29->SetBinContent(6,9.254746e-05); METJets29->SetBinError(1,0.0002224564); METJets29->SetBinError(2,0.0007384491); METJets29->SetBinError(3,0.000574863); METJets29->SetBinError(4,0.0002414328); METJets29->SetBinError(5,7.556468e-05); METJets29->SetBinError(6,3.778234e-05); METJets29->SetEntries(4164); ci = TColor::GetColor("#ff0000"); METJets29->SetFillColor(ci); ci = TColor::GetColor("#ff0000"); METJets29->SetLineColor(ci); ci = TColor::GetColor("#ff0000"); METJets29->SetMarkerColor(ci); METJets29->SetMarkerStyle(20); METJets29->GetXaxis()->SetTitle("METJets"); METJets29->GetXaxis()->SetLabelFont(42); METJets29->GetXaxis()->SetLabelSize(0.035); METJets29->GetXaxis()->SetTitleSize(0.035); METJets29->GetXaxis()->SetTitleFont(42); METJets29->GetYaxis()->SetTitle("Events/pb"); METJets29->GetYaxis()->SetLabelFont(42); METJets29->GetYaxis()->SetLabelSize(0.035); METJets29->GetYaxis()->SetTitleSize(0.035); METJets29->GetYaxis()->SetTitleFont(42); METJets29->GetZaxis()->SetLabelFont(42); METJets29->GetZaxis()->SetLabelSize(0.035); METJets29->GetZaxis()->SetTitleSize(0.035); METJets29->GetZaxis()->SetTitleFont(42); METJets->Add(METJets,""); TH1D *METJets30 = new TH1D("METJets30"," Number of jets in MET hemisphere",15,0,15); METJets30->SetBinContent(2,0.000335433); METJets30->SetBinContent(3,0.000335433); METJets30->SetBinContent(4,0.0002180314); METJets30->SetBinContent(5,0.0001341732); METJets30->SetBinError(2,7.500509e-05); METJets30->SetBinError(3,7.500509e-05); METJets30->SetBinError(4,6.047104e-05); METJets30->SetBinError(5,4.743738e-05); METJets30->SetEntries(61); ci = TColor::GetColor("#0000ff"); METJets30->SetFillColor(ci); ci = TColor::GetColor("#0000ff"); METJets30->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); METJets30->SetMarkerColor(ci); METJets30->SetMarkerStyle(21); METJets30->GetXaxis()->SetTitle("METJets"); METJets30->GetXaxis()->SetLabelFont(42); METJets30->GetXaxis()->SetLabelSize(0.035); METJets30->GetXaxis()->SetTitleSize(0.035); METJets30->GetXaxis()->SetTitleFont(42); METJets30->GetYaxis()->SetTitle("Events/pb"); METJets30->GetYaxis()->SetLabelFont(42); METJets30->GetYaxis()->SetLabelSize(0.035); METJets30->GetYaxis()->SetTitleSize(0.035); METJets30->GetYaxis()->SetTitleFont(42); METJets30->GetZaxis()->SetLabelFont(42); METJets30->GetZaxis()->SetLabelSize(0.035); METJets30->GetZaxis()->SetTitleSize(0.035); METJets30->GetZaxis()->SetTitleFont(42); METJets->Add(METJets,""); METJets->Draw("nostack"); TPaveText *pt = new TPaveText(0.3872701,0.94,0.6127299,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); TText *AText = pt->AddText("METJets"); pt->Draw(); TLegend *leg = new TLegend(0.54023,0.639881,0.938218,0.924107,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextSize(0.034965); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); TLegendEntry *entry=leg->AddEntry("METJets","METJets_QCD","lp"); ci = TColor::GetColor("#00cc00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); ci = TColor::GetColor("#00cc00"); entry->SetMarkerColor(ci); entry->SetMarkerStyle(22); entry->SetMarkerSize(1); entry->SetTextFont(42); entry=leg->AddEntry("METJets","METJets_WJetsToLNu","lp"); ci = TColor::GetColor("#00ffff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); ci = TColor::GetColor("#00ffff"); entry->SetMarkerColor(ci); entry->SetMarkerStyle(20); entry->SetMarkerSize(1); entry->SetTextFont(42); entry=leg->AddEntry("METJets","METJets_ZJetsToNuNu","lp"); ci = TColor::GetColor("#ffcc00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); ci = TColor::GetColor("#ffcc00"); entry->SetMarkerColor(ci); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(42); entry=leg->AddEntry("METJets","METJets_signal","lp"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); ci = TColor::GetColor("#ff0000"); entry->SetMarkerColor(ci); entry->SetMarkerStyle(20); entry->SetMarkerSize(1); entry->SetTextFont(42); entry=leg->AddEntry("METJets","METJets_ttbar","lp"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); ci = TColor::GetColor("#0000ff"); entry->SetMarkerColor(ci); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(42); leg->Draw(); METJets->Modified(); METJets->cd(); METJets->SetSelected(METJets); }
void draw_qa_sim(TString inFileName="sim.qa.root") { gStyle->SetPalette(1); TFile* inFile = new TFile(inFileName.Data()); TH1F* fhNofEvents = (TH1F*)inFile->Get("STSSimulationQA/hNofEvents"); TH1F* fhNofStsStations = (TH1F*)inFile->Get("STSSimulationQA/hNofStsStations"); Int_t nofStations = fhNofStsStations->GetBinContent(1); Int_t fShowStation = 4; Int_t fNEvents = fhNofEvents->GetBinContent(1); TH1F* fhMomAll = (TH1F*)inFile->Get("STSSimulationQA/hMomAll"); TH1F* fhMomRec = (TH1F*)inFile->Get("STSSimulationQA/hMomRec"); TH2F* fhYPtMapRec = (TH2F*)inFile->Get("STSSimulationQA/hYPtMapRec"); TH1F* fhStsPointsRec = (TH1F*)inFile->Get("STSSimulationQA/hStsPointsRec"); TH3F* fhStsPointsPosition = (TH3F*)inFile->Get("STSSimulationQA/hStsPointsPosition"); TH2F* fhStationPoints[10]; for ( Int_t ist = 0 ; ist < nofStations ; ist++ ) fhStationPoints[ist] = (TH2F*)inFile->Get(Form("STSSimulationQA/hStationPoints%i",ist+1)); Double_t tracksPerEvent = (Double_t)(fhMomAll->GetEntries())/((Double_t)fNEvents); Double_t pointsPerEvent = (Double_t)(fhStsPointsPosition->GetEntries())/((Double_t)fNEvents); TCanvas* simCanvas = new TCanvas("StsSim","Sts simulation",10,10,600,900); TPad* simPad[10]; simPad[0] = new TPad("titlePad", "Title pad" ,0.01,0.91,0.99,0.99); simPad[1] = new TPad("momentumPad","Momentum pad" ,0.01,0.46,0.49,0.89); simPad[2] = new TPad("yptPad", "y-pt pad" ,0.01,0.01,0.49,0.44); simPad[3] = new TPad("pointPad", "Points per track pad" ,0.51,0.61,0.99,0.89); simPad[4] = new TPad("stationPad", "Points on 1st station pad",0.51,0.31,0.99,0.59); simPad[5] = new TPad("printoutPad","Print information pad ",0.51,0.01,0.99,0.29); simPad[1]->SetLogy(); for ( Int_t ipad = 0 ; ipad < 6 ; ipad++ ) { simPad[ipad]->SetFillColor(0); simPad[ipad]->SetBorderMode(0); simPad[ipad]->Draw(); } simPad[0]->cd(); TLegend* brp = new TLegend(0.1,0.1,0.9,0.9,"STS simulation"); brp->SetTextAlign(22); brp->SetTextSize(0.6); brp->SetTextColor(1); brp->SetBorderSize(0); brp->SetFillColor(0); brp->Draw(); simPad[0]->Update(); simPad[1]->cd(); // fhMomAll->Draw(); fhMomRec->Draw(); simPad[1]->Update(); simPad[2]->cd(); fhYPtMapRec->Draw("colz"); simPad[2]->Update(); simPad[3]->cd(); fhStsPointsRec->Draw(); simPad[3]->Update(); simPad[4]->cd(); fhStationPoints[0]->Draw(); fhStationPoints[0]->Draw("colz"); simPad[4]->Update(); simPad[5]->cd(); TPaveText* printoutPave = new TPaveText(0.1,0.1,0.9,0.9); printoutPave->SetTextAlign(22); printoutPave->SetTextSize(0.1); printoutPave->SetTextColor(1); printoutPave->SetBorderSize(0); printoutPave->SetFillColor(0); printoutPave->AddText(Form("%i events",fNEvents)); printoutPave->AddText(Form("tracks/event = %3.2f",tracksPerEvent)); printoutPave->AddText(Form("points/event = %3.2f",pointsPerEvent)); simPad[5]->Clear(); printoutPave->Draw(); simPad[5]->Update(); }
void TracktoLCTX_2015all_sameYrange() { //=========Macro generated from canvas: TracktoLCTX/TracktoLCTX //========= (Fri Aug 5 08:13:37 2016) by ROOT version6.06/01 TCanvas *TracktoLCTX = new TCanvas("TracktoLCTX", "TracktoLCTX",0,0,500,500); gStyle->SetOptStat(0); TracktoLCTX->SetHighLightColor(2); TracktoLCTX->Range(-50,-2.848556,50,2.626708); TracktoLCTX->SetFillColor(0); TracktoLCTX->SetBorderMode(0); TracktoLCTX->SetBorderSize(2); TracktoLCTX->SetLogy(); TracktoLCTX->SetFrameBorderMode(0); TracktoLCTX->SetFrameBorderMode(0); TH1D *TracktoLCTX_1__109 = new TH1D("TracktoLCTX_1__109","TracktoLCTX",100,-40,40); TracktoLCTX_1__109->SetBinContent(0,371.1851); TracktoLCTX_1__109->SetBinContent(13,0.001225956); TracktoLCTX_1__109->SetBinContent(14,0.001225956); TracktoLCTX_1__109->SetBinContent(17,0.002451912); TracktoLCTX_1__109->SetBinContent(18,0.003677868); TracktoLCTX_1__109->SetBinContent(19,0.00919467); TracktoLCTX_1__109->SetBinContent(20,0.007355736); TracktoLCTX_1__109->SetBinContent(21,0.0196153); TracktoLCTX_1__109->SetBinContent(22,0.02084125); TracktoLCTX_1__109->SetBinContent(23,0.03310081); TracktoLCTX_1__109->SetBinContent(24,0.03187485); TracktoLCTX_1__109->SetBinContent(25,0.06007184); TracktoLCTX_1__109->SetBinContent(26,0.06007184); TracktoLCTX_1__109->SetBinContent(27,0.07968714); TracktoLCTX_1__109->SetBinContent(28,0.1293384); TracktoLCTX_1__109->SetBinContent(29,0.1642781); TracktoLCTX_1__109->SetBinContent(30,0.1802155); TracktoLCTX_1__109->SetBinContent(31,0.2206721); TracktoLCTX_1__109->SetBinContent(32,0.2556118); TracktoLCTX_1__109->SetBinContent(33,0.3144577); TracktoLCTX_1__109->SetBinContent(34,0.4051784); TracktoLCTX_1__109->SetBinContent(35,0.4260197); TracktoLCTX_1__109->SetBinContent(36,0.5247091); TracktoLCTX_1__109->SetBinContent(37,0.5406466); TracktoLCTX_1__109->SetBinContent(38,0.5743604); TracktoLCTX_1__109->SetBinContent(39,0.638723); TracktoLCTX_1__109->SetBinContent(40,0.7607057); TracktoLCTX_1__109->SetBinContent(41,0.89127); TracktoLCTX_1__109->SetBinContent(42,0.9164021); TracktoLCTX_1__109->SetBinContent(43,0.9801518); TracktoLCTX_1__109->SetBinContent(44,1.127879); TracktoLCTX_1__109->SetBinContent(45,1.162819); TracktoLCTX_1__109->SetBinContent(46,1.39759); TracktoLCTX_1__109->SetBinContent(47,1.54593); TracktoLCTX_1__109->SetBinContent(48,1.858549); TracktoLCTX_1__109->SetBinContent(49,3.018917); TracktoLCTX_1__109->SetBinContent(50,31.96067); TracktoLCTX_1__109->SetBinContent(51,31.44332); TracktoLCTX_1__109->SetBinContent(52,2.99072); TracktoLCTX_1__109->SetBinContent(53,1.805833); TracktoLCTX_1__109->SetBinContent(54,1.601098); TracktoLCTX_1__109->SetBinContent(55,1.406171); TracktoLCTX_1__109->SetBinContent(56,1.14443); TracktoLCTX_1__109->SetBinContent(57,1.069034); TracktoLCTX_1__109->SetBinContent(58,1.034707); TracktoLCTX_1__109->SetBinContent(59,0.8661379); TracktoLCTX_1__109->SetBinContent(60,0.836102); TracktoLCTX_1__109->SetBinContent(61,0.6877613); TracktoLCTX_1__109->SetBinContent(62,0.6822445); TracktoLCTX_1__109->SetBinContent(63,0.6540475); TracktoLCTX_1__109->SetBinContent(64,0.5418725); TracktoLCTX_1__109->SetBinContent(65,0.4425701); TracktoLCTX_1__109->SetBinContent(66,0.4149861); TracktoLCTX_1__109->SetBinContent(67,0.3910799); TracktoLCTX_1__109->SetBinContent(68,0.2930035); TracktoLCTX_1__109->SetBinContent(69,0.2850348); TracktoLCTX_1__109->SetBinContent(70,0.2537729); TracktoLCTX_1__109->SetBinContent(71,0.1814415); TracktoLCTX_1__109->SetBinContent(72,0.139759); TracktoLCTX_1__109->SetBinContent(73,0.1238215); TracktoLCTX_1__109->SetBinContent(74,0.09439861); TracktoLCTX_1__109->SetBinContent(75,0.06558864); TracktoLCTX_1__109->SetBinContent(76,0.05394206); TracktoLCTX_1__109->SetBinContent(77,0.02942294); TracktoLCTX_1__109->SetBinContent(78,0.0306489); TracktoLCTX_1__109->SetBinContent(79,0.02819699); TracktoLCTX_1__109->SetBinContent(80,0.01838934); TracktoLCTX_1__109->SetBinContent(81,0.01716338); TracktoLCTX_1__109->SetBinContent(82,0.02084125); TracktoLCTX_1__109->SetBinContent(83,0.003677868); TracktoLCTX_1__109->SetBinContent(84,0.00612978); TracktoLCTX_1__109->SetBinContent(85,0.007355736); TracktoLCTX_1__109->SetBinContent(86,0.003677868); TracktoLCTX_1__109->SetBinContent(87,0.002451912); TracktoLCTX_1__109->SetBinContent(89,0.001225956); TracktoLCTX_1__109->SetBinContent(90,0.001225956); TracktoLCTX_1__109->SetBinContent(96,0.001225956); TracktoLCTX_1__109->SetMinimum(0.005); TracktoLCTX_1__109->SetMaximum(120); TracktoLCTX_1__109->SetEntries(768682); TracktoLCTX_1__109->SetStats(0); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#ff00ff"); TracktoLCTX_1__109->SetLineColor(ci); ci = TColor::GetColor("#ff00ff"); TracktoLCTX_1__109->SetMarkerColor(ci); TracktoLCTX_1__109->GetXaxis()->SetTitle("cm"); TracktoLCTX_1__109->GetYaxis()->SetTitle("scaled number of entries"); TracktoLCTX_1__109->Draw("H"); TLegend *leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); TLegendEntry *entry=leg->AddEntry("TracktoLCTX_1","ME11A: mean:-0.0cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_2","ME11B: mean:-0.0cm;RMS:4.6cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_3","ME12+13: mean:0.0cm;RMS:3.5cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_4","ME2: mean:0.0cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_5","ME3: mean:0.1cm;RMS:2.8cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_6","ME4: mean:0.0cm;RMS:2.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *TracktoLCTX_2__110 = new TH1D("TracktoLCTX_2__110","TracktoLCTX",100,-40,40); TracktoLCTX_2__110->SetBinContent(0,265.8331); TracktoLCTX_2__110->SetBinContent(4,0.001044117); TracktoLCTX_2__110->SetBinContent(5,0.002088233); TracktoLCTX_2__110->SetBinContent(6,0.002088233); TracktoLCTX_2__110->SetBinContent(7,0.001566175); TracktoLCTX_2__110->SetBinContent(8,0.002610291); TracktoLCTX_2__110->SetBinContent(9,0.004437495); TracktoLCTX_2__110->SetBinContent(10,0.00313235); TracktoLCTX_2__110->SetBinContent(11,0.004698524); TracktoLCTX_2__110->SetBinContent(12,0.006786757); TracktoLCTX_2__110->SetBinContent(13,0.01357351); TracktoLCTX_2__110->SetBinContent(14,0.01409557); TracktoLCTX_2__110->SetBinContent(15,0.01566175); TracktoLCTX_2__110->SetBinContent(16,0.03054041); TracktoLCTX_2__110->SetBinContent(17,0.02923526); TracktoLCTX_2__110->SetBinContent(18,0.0349779); TracktoLCTX_2__110->SetBinContent(19,0.03706614); TracktoLCTX_2__110->SetBinContent(20,0.04072054); TracktoLCTX_2__110->SetBinContent(21,0.05559921); TracktoLCTX_2__110->SetBinContent(22,0.05063965); TracktoLCTX_2__110->SetBinContent(23,0.0707389); TracktoLCTX_2__110->SetBinContent(24,0.08613961); TracktoLCTX_2__110->SetBinContent(25,0.09658078); TracktoLCTX_2__110->SetBinContent(26,0.1033675); TracktoLCTX_2__110->SetBinContent(27,0.1328638); TracktoLCTX_2__110->SetBinContent(28,0.1273822); TracktoLCTX_2__110->SetBinContent(29,0.1498307); TracktoLCTX_2__110->SetBinContent(30,0.1670586); TracktoLCTX_2__110->SetBinContent(31,0.1871579); TracktoLCTX_2__110->SetBinContent(32,0.1819373); TracktoLCTX_2__110->SetBinContent(33,0.2250071); TracktoLCTX_2__110->SetBinContent(34,0.2265733); TracktoLCTX_2__110->SetBinContent(35,0.2592019); TracktoLCTX_2__110->SetBinContent(36,0.26886); TracktoLCTX_2__110->SetBinContent(37,0.2975732); TracktoLCTX_2__110->SetBinContent(38,0.2949629); TracktoLCTX_2__110->SetBinContent(39,0.3069703); TracktoLCTX_2__110->SetBinContent(40,0.3382938); TracktoLCTX_2__110->SetBinContent(41,0.3818856); TracktoLCTX_2__110->SetBinContent(42,0.4147753); TracktoLCTX_2__110->SetBinContent(43,0.4419223); TracktoLCTX_2__110->SetBinContent(44,0.4980436); TracktoLCTX_2__110->SetBinContent(45,0.6136795); TracktoLCTX_2__110->SetBinContent(46,0.7267051); TracktoLCTX_2__110->SetBinContent(47,0.9898225); TracktoLCTX_2__110->SetBinContent(48,1.439054); TracktoLCTX_2__110->SetBinContent(49,3.488393); TracktoLCTX_2__110->SetBinContent(50,37.54382); TracktoLCTX_2__110->SetBinContent(51,36.99696); TracktoLCTX_2__110->SetBinContent(52,3.337257); TracktoLCTX_2__110->SetBinContent(53,1.355263); TracktoLCTX_2__110->SetBinContent(54,0.9175174); TracktoLCTX_2__110->SetBinContent(55,0.7669036); TracktoLCTX_2__110->SetBinContent(56,0.5849663); TracktoLCTX_2__110->SetBinContent(57,0.5024811); TracktoLCTX_2__110->SetBinContent(58,0.4442716); TracktoLCTX_2__110->SetBinContent(59,0.4012018); TracktoLCTX_2__110->SetBinContent(60,0.3897165); TracktoLCTX_2__110->SetBinContent(61,0.3427313); TracktoLCTX_2__110->SetBinContent(62,0.3325511); TracktoLCTX_2__110->SetBinContent(63,0.2994004); TracktoLCTX_2__110->SetBinContent(64,0.2834776); TracktoLCTX_2__110->SetBinContent(65,0.2659887); TracktoLCTX_2__110->SetBinContent(66,0.2620732); TracktoLCTX_2__110->SetBinContent(67,0.2466725); TracktoLCTX_2__110->SetBinContent(68,0.2020365); TracktoLCTX_2__110->SetBinContent(69,0.2114336); TracktoLCTX_2__110->SetBinContent(70,0.1850697); TracktoLCTX_2__110->SetBinContent(71,0.1571395); TracktoLCTX_2__110->SetBinContent(72,0.1459153); TracktoLCTX_2__110->SetBinContent(73,0.1312977); TracktoLCTX_2__110->SetBinContent(74,0.1062389); TracktoLCTX_2__110->SetBinContent(75,0.1138087); TracktoLCTX_2__110->SetBinContent(76,0.09684181); TracktoLCTX_2__110->SetBinContent(77,0.07856977); TracktoLCTX_2__110->SetBinContent(78,0.07308816); TracktoLCTX_2__110->SetBinContent(79,0.06473523); TracktoLCTX_2__110->SetBinContent(80,0.05507715); TracktoLCTX_2__110->SetBinContent(81,0.05951464); TracktoLCTX_2__110->SetBinContent(82,0.03445585); TracktoLCTX_2__110->SetBinContent(83,0.02558086); TracktoLCTX_2__110->SetBinContent(84,0.01827204); TracktoLCTX_2__110->SetBinContent(85,0.0287132); TracktoLCTX_2__110->SetBinContent(86,0.01670586); TracktoLCTX_2__110->SetBinContent(87,0.0125294); TracktoLCTX_2__110->SetBinContent(88,0.01409557); TracktoLCTX_2__110->SetBinContent(89,0.006264699); TracktoLCTX_2__110->SetBinContent(90,0.005220583); TracktoLCTX_2__110->SetBinContent(91,0.007830874); TracktoLCTX_2__110->SetBinContent(92,0.00313235); TracktoLCTX_2__110->SetBinContent(93,0.00313235); TracktoLCTX_2__110->SetBinContent(94,0.001044117); TracktoLCTX_2__110->SetBinContent(95,0.001044117); TracktoLCTX_2__110->SetBinContent(96,0.001044117); TracktoLCTX_2__110->SetBinContent(97,0.001044117); TracktoLCTX_2__110->SetBinContent(98,0.0005220583); TracktoLCTX_2__110->SetBinContent(101,0.0005220583); TracktoLCTX_2__110->SetEntries(1401505); TracktoLCTX_2__110->SetStats(0); ci = TColor::GetColor("#ff9999"); TracktoLCTX_2__110->SetLineColor(ci); ci = TColor::GetColor("#ff9999"); TracktoLCTX_2__110->SetMarkerColor(ci); TracktoLCTX_2__110->GetXaxis()->SetTitle("cm"); TracktoLCTX_2__110->GetYaxis()->SetTitle("scaled number of entries"); TracktoLCTX_2__110->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("TracktoLCTX_1","ME11A: mean:-0.0cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_2","ME11B: mean:-0.0cm;RMS:4.6cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_3","ME12+13: mean:0.0cm;RMS:3.5cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_4","ME2: mean:0.0cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_5","ME3: mean:0.1cm;RMS:2.8cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_6","ME4: mean:0.0cm;RMS:2.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *TracktoLCTX_3__111 = new TH1D("TracktoLCTX_3__111","TracktoLCTX",100,-40,40); TracktoLCTX_3__111->SetBinContent(0,87.79784); TracktoLCTX_3__111->SetBinContent(1,0.01559486); TracktoLCTX_3__111->SetBinContent(2,0.01149095); TracktoLCTX_3__111->SetBinContent(3,0.01969877); TracktoLCTX_3__111->SetBinContent(4,0.01313252); TracktoLCTX_3__111->SetBinContent(5,0.004103911); TracktoLCTX_3__111->SetBinContent(6,0.01067017); TracktoLCTX_3__111->SetBinContent(7,0.01231173); TracktoLCTX_3__111->SetBinContent(8,0.02051956); TracktoLCTX_3__111->SetBinContent(9,0.01067017); TracktoLCTX_3__111->SetBinContent(10,0.01969877); TracktoLCTX_3__111->SetBinContent(11,0.02380268); TracktoLCTX_3__111->SetBinContent(12,0.01231173); TracktoLCTX_3__111->SetBinContent(13,0.0139533); TracktoLCTX_3__111->SetBinContent(14,0.01231173); TracktoLCTX_3__111->SetBinContent(15,0.01723643); TracktoLCTX_3__111->SetBinContent(16,0.0229819); TracktoLCTX_3__111->SetBinContent(17,0.02380268); TracktoLCTX_3__111->SetBinContent(18,0.01641564); TracktoLCTX_3__111->SetBinContent(19,0.02544425); TracktoLCTX_3__111->SetBinContent(20,0.02462347); TracktoLCTX_3__111->SetBinContent(21,0.03324168); TracktoLCTX_3__111->SetBinContent(22,0.03160011); TracktoLCTX_3__111->SetBinContent(23,0.02544425); TracktoLCTX_3__111->SetBinContent(24,0.02954816); TracktoLCTX_3__111->SetBinContent(25,0.03611442); TracktoLCTX_3__111->SetBinContent(26,0.01805721); TracktoLCTX_3__111->SetBinContent(27,0.03201051); TracktoLCTX_3__111->SetBinContent(28,0.04801576); TracktoLCTX_3__111->SetBinContent(29,0.03036894); TracktoLCTX_3__111->SetBinContent(30,0.03036894); TracktoLCTX_3__111->SetBinContent(31,0.03118972); TracktoLCTX_3__111->SetBinContent(32,0.03611442); TracktoLCTX_3__111->SetBinContent(33,0.04432224); TracktoLCTX_3__111->SetBinContent(34,0.04924693); TracktoLCTX_3__111->SetBinContent(35,0.04268067); TracktoLCTX_3__111->SetBinContent(36,0.0599171); TracktoLCTX_3__111->SetBinContent(37,0.0554028); TracktoLCTX_3__111->SetBinContent(38,0.07551196); TracktoLCTX_3__111->SetBinContent(39,0.08618213); TracktoLCTX_3__111->SetBinContent(40,0.08495096); TracktoLCTX_3__111->SetBinContent(41,0.1116264); TracktoLCTX_3__111->SetBinContent(42,0.1616941); TracktoLCTX_3__111->SetBinContent(43,0.2265359); TracktoLCTX_3__111->SetBinContent(44,0.3422662); TracktoLCTX_3__111->SetBinContent(45,0.6114827); TracktoLCTX_3__111->SetBinContent(46,1.085895); TracktoLCTX_3__111->SetBinContent(47,2.150449); TracktoLCTX_3__111->SetBinContent(48,4.908688); TracktoLCTX_3__111->SetBinContent(49,12.17056); TracktoLCTX_3__111->SetBinContent(50,25.97283); TracktoLCTX_3__111->SetBinContent(51,26.87815); TracktoLCTX_3__111->SetBinContent(52,12.93183); TracktoLCTX_3__111->SetBinContent(53,5.269422); TracktoLCTX_3__111->SetBinContent(54,2.273567); TracktoLCTX_3__111->SetBinContent(55,1.078918); TracktoLCTX_3__111->SetBinContent(56,0.5761891); TracktoLCTX_3__111->SetBinContent(57,0.3681208); TracktoLCTX_3__111->SetBinContent(58,0.2150449); TracktoLCTX_3__111->SetBinContent(59,0.1662084); TracktoLCTX_3__111->SetBinContent(60,0.1239381); TracktoLCTX_3__111->SetBinContent(61,0.08946526); TracktoLCTX_3__111->SetBinContent(62,0.08536135); TracktoLCTX_3__111->SetBinContent(63,0.05786515); TracktoLCTX_3__111->SetBinContent(64,0.06237945); TracktoLCTX_3__111->SetBinContent(65,0.05909632); TracktoLCTX_3__111->SetBinContent(66,0.04021833); TracktoLCTX_3__111->SetBinContent(67,0.04185989); TracktoLCTX_3__111->SetBinContent(68,0.0508885); TracktoLCTX_3__111->SetBinContent(69,0.03939755); TracktoLCTX_3__111->SetBinContent(70,0.03857676); TracktoLCTX_3__111->SetBinContent(71,0.03529363); TracktoLCTX_3__111->SetBinContent(72,0.02954816); TracktoLCTX_3__111->SetBinContent(73,0.02626503); TracktoLCTX_3__111->SetBinContent(74,0.02790659); TracktoLCTX_3__111->SetBinContent(75,0.02134034); TracktoLCTX_3__111->SetBinContent(76,0.02503386); TracktoLCTX_3__111->SetBinContent(77,0.03036894); TracktoLCTX_3__111->SetBinContent(78,0.02421308); TracktoLCTX_3__111->SetBinContent(79,0.02954816); TracktoLCTX_3__111->SetBinContent(80,0.01969877); TracktoLCTX_3__111->SetBinContent(81,0.02134034); TracktoLCTX_3__111->SetBinContent(82,0.02134034); TracktoLCTX_3__111->SetBinContent(83,0.03036894); TracktoLCTX_3__111->SetBinContent(84,0.03118972); TracktoLCTX_3__111->SetBinContent(85,0.01641564); TracktoLCTX_3__111->SetBinContent(86,0.02134034); TracktoLCTX_3__111->SetBinContent(87,0.01354291); TracktoLCTX_3__111->SetBinContent(88,0.01805721); TracktoLCTX_3__111->SetBinContent(89,0.01969877); TracktoLCTX_3__111->SetBinContent(90,0.009028604); TracktoLCTX_3__111->SetBinContent(91,0.0139533); TracktoLCTX_3__111->SetBinContent(92,0.01723643); TracktoLCTX_3__111->SetBinContent(93,0.01231173); TracktoLCTX_3__111->SetBinContent(94,0.01477408); TracktoLCTX_3__111->SetBinContent(95,0.01313252); TracktoLCTX_3__111->SetBinContent(96,0.0139533); TracktoLCTX_3__111->SetBinContent(97,0.01149095); TracktoLCTX_3__111->SetBinContent(98,0.01313252); TracktoLCTX_3__111->SetBinContent(99,0.01231173); TracktoLCTX_3__111->SetBinContent(100,0.006566258); TracktoLCTX_3__111->SetBinContent(101,0.1218862); TracktoLCTX_3__111->SetEntries(457904); TracktoLCTX_3__111->SetStats(0); TracktoLCTX_3__111->GetXaxis()->SetTitle("cm"); TracktoLCTX_3__111->GetYaxis()->SetTitle("scaled number of entries"); TracktoLCTX_3__111->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("TracktoLCTX_1","ME11A: mean:-0.0cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_2","ME11B: mean:-0.0cm;RMS:4.6cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_3","ME12+13: mean:0.0cm;RMS:3.5cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_4","ME2: mean:0.0cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_5","ME3: mean:0.1cm;RMS:2.8cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_6","ME4: mean:0.0cm;RMS:2.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *TracktoLCTX_4__112 = new TH1D("TracktoLCTX_4__112","TracktoLCTX",100,-40,40); TracktoLCTX_4__112->SetBinContent(0,201.0141); TracktoLCTX_4__112->SetBinContent(1,0.0196316); TracktoLCTX_4__112->SetBinContent(2,0.01895928); TracktoLCTX_4__112->SetBinContent(3,0.02164854); TracktoLCTX_4__112->SetBinContent(4,0.02205193); TracktoLCTX_4__112->SetBinContent(5,0.02379995); TracktoLCTX_4__112->SetBinContent(6,0.01990052); TracktoLCTX_4__112->SetBinContent(7,0.01990052); TracktoLCTX_4__112->SetBinContent(8,0.02541351); TracktoLCTX_4__112->SetBinContent(9,0.02097623); TracktoLCTX_4__112->SetBinContent(10,0.02501012); TracktoLCTX_4__112->SetBinContent(11,0.02541351); TracktoLCTX_4__112->SetBinContent(12,0.0268926); TracktoLCTX_4__112->SetBinContent(13,0.01990052); TracktoLCTX_4__112->SetBinContent(14,0.02474119); TracktoLCTX_4__112->SetBinContent(15,0.02554797); TracktoLCTX_4__112->SetBinContent(16,0.02729599); TracktoLCTX_4__112->SetBinContent(17,0.02420334); TracktoLCTX_4__112->SetBinContent(18,0.03375021); TracktoLCTX_4__112->SetBinContent(19,0.03119542); TracktoLCTX_4__112->SetBinContent(20,0.02716153); TracktoLCTX_4__112->SetBinContent(21,0.02608582); TracktoLCTX_4__112->SetBinContent(22,0.02823723); TracktoLCTX_4__112->SetBinContent(23,0.03442253); TracktoLCTX_4__112->SetBinContent(24,0.02864062); TracktoLCTX_4__112->SetBinContent(25,0.03038864); TracktoLCTX_4__112->SetBinContent(26,0.0279683); TracktoLCTX_4__112->SetBinContent(27,0.02635475); TracktoLCTX_4__112->SetBinContent(28,0.03334682); TracktoLCTX_4__112->SetBinContent(29,0.03603608); TracktoLCTX_4__112->SetBinContent(30,0.0428937); TracktoLCTX_4__112->SetBinContent(31,0.03872534); TracktoLCTX_4__112->SetBinContent(32,0.03630501); TracktoLCTX_4__112->SetBinContent(33,0.04612081); TracktoLCTX_4__112->SetBinContent(34,0.04437279); TracktoLCTX_4__112->SetBinContent(35,0.05405413); TracktoLCTX_4__112->SetBinContent(36,0.0610462); TracktoLCTX_4__112->SetBinContent(37,0.06373546); TracktoLCTX_4__112->SetBinContent(38,0.06481117); TracktoLCTX_4__112->SetBinContent(39,0.08995575); TracktoLCTX_4__112->SetBinContent(40,0.0930484); TracktoLCTX_4__112->SetBinContent(41,0.1266641); TracktoLCTX_4__112->SetBinContent(42,0.1819284); TracktoLCTX_4__112->SetBinContent(43,0.2405543); TracktoLCTX_4__112->SetBinContent(44,0.3701766); TracktoLCTX_4__112->SetBinContent(45,0.5730813); TracktoLCTX_4__112->SetBinContent(46,0.95778); TracktoLCTX_4__112->SetBinContent(47,1.803821); TracktoLCTX_4__112->SetBinContent(48,3.918386); TracktoLCTX_4__112->SetBinContent(49,10.64086); TracktoLCTX_4__112->SetBinContent(50,28.39065); TracktoLCTX_4__112->SetBinContent(51,29.52283); TracktoLCTX_4__112->SetBinContent(52,11.82629); TracktoLCTX_4__112->SetBinContent(53,4.280226); TracktoLCTX_4__112->SetBinContent(54,1.936267); TracktoLCTX_4__112->SetBinContent(55,1.044509); TracktoLCTX_4__112->SetBinContent(56,0.5765774); TracktoLCTX_4__112->SetBinContent(57,0.3551168); TracktoLCTX_4__112->SetBinContent(58,0.2312764); TracktoLCTX_4__112->SetBinContent(59,0.1687511); TracktoLCTX_4__112->SetBinContent(60,0.1266641); TracktoLCTX_4__112->SetBinContent(61,0.09681336); TracktoLCTX_4__112->SetBinContent(62,0.07919871); TracktoLCTX_4__112->SetBinContent(63,0.07906425); TracktoLCTX_4__112->SetBinContent(64,0.06682811); TracktoLCTX_4__112->SetBinContent(65,0.04867561); TracktoLCTX_4__112->SetBinContent(66,0.04948238); TracktoLCTX_4__112->SetBinContent(67,0.04356601); TracktoLCTX_4__112->SetBinContent(68,0.04222138); TracktoLCTX_4__112->SetBinContent(69,0.03617055); TracktoLCTX_4__112->SetBinContent(70,0.03348129); TracktoLCTX_4__112->SetBinContent(71,0.03294344); TracktoLCTX_4__112->SetBinContent(72,0.03442253); TracktoLCTX_4__112->SetBinContent(73,0.0330779); TracktoLCTX_4__112->SetBinContent(74,0.02769938); TracktoLCTX_4__112->SetBinContent(75,0.03173327); TracktoLCTX_4__112->SetBinContent(76,0.03159881); TracktoLCTX_4__112->SetBinContent(77,0.0341536); TracktoLCTX_4__112->SetBinContent(78,0.02635475); TracktoLCTX_4__112->SetBinContent(79,0.03065756); TracktoLCTX_4__112->SetBinContent(80,0.02635475); TracktoLCTX_4__112->SetBinContent(81,0.02245532); TracktoLCTX_4__112->SetBinContent(82,0.0258169); TracktoLCTX_4__112->SetBinContent(83,0.02985079); TracktoLCTX_4__112->SetBinContent(84,0.03011971); TracktoLCTX_4__112->SetBinContent(85,0.02339656); TracktoLCTX_4__112->SetBinContent(86,0.02474119); TracktoLCTX_4__112->SetBinContent(87,0.02608582); TracktoLCTX_4__112->SetBinContent(88,0.01936267); TracktoLCTX_4__112->SetBinContent(89,0.02635475); TracktoLCTX_4__112->SetBinContent(90,0.02312764); TracktoLCTX_4__112->SetBinContent(91,0.01990052); TracktoLCTX_4__112->SetBinContent(92,0.01882482); TracktoLCTX_4__112->SetBinContent(93,0.02043838); TracktoLCTX_4__112->SetBinContent(94,0.02178301); TracktoLCTX_4__112->SetBinContent(95,0.01976606); TracktoLCTX_4__112->SetBinContent(96,0.02205193); TracktoLCTX_4__112->SetBinContent(97,0.01990052); TracktoLCTX_4__112->SetBinContent(98,0.02043838); TracktoLCTX_4__112->SetBinContent(99,0.0196316); TracktoLCTX_4__112->SetBinContent(100,0.01909375); TracktoLCTX_4__112->SetBinContent(101,0.4657798); TracktoLCTX_4__112->SetEntries(2242103); TracktoLCTX_4__112->SetStats(0); ci = TColor::GetColor("#ff0000"); TracktoLCTX_4__112->SetLineColor(ci); ci = TColor::GetColor("#ff0000"); TracktoLCTX_4__112->SetMarkerColor(ci); TracktoLCTX_4__112->GetXaxis()->SetTitle("cm"); TracktoLCTX_4__112->GetYaxis()->SetTitle("scaled number of entries"); TracktoLCTX_4__112->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("TracktoLCTX_1","ME11A: mean:-0.0cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_2","ME11B: mean:-0.0cm;RMS:4.6cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_3","ME12+13: mean:0.0cm;RMS:3.5cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_4","ME2: mean:0.0cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_5","ME3: mean:0.1cm;RMS:2.8cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_6","ME4: mean:0.0cm;RMS:2.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *TracktoLCTX_5__113 = new TH1D("TracktoLCTX_5__113","TracktoLCTX",100,-40,40); TracktoLCTX_5__113->SetBinContent(0,158.5363); TracktoLCTX_5__113->SetBinContent(1,0.006475526); TracktoLCTX_5__113->SetBinContent(2,0.009250751); TracktoLCTX_5__113->SetBinContent(3,0.008325676); TracktoLCTX_5__113->SetBinContent(4,0.008017317); TracktoLCTX_5__113->SetBinContent(5,0.007092242); TracktoLCTX_5__113->SetBinContent(6,0.007708959); TracktoLCTX_5__113->SetBinContent(7,0.009867468); TracktoLCTX_5__113->SetBinContent(8,0.009867468); TracktoLCTX_5__113->SetBinContent(9,0.01017583); TracktoLCTX_5__113->SetBinContent(10,0.008325676); TracktoLCTX_5__113->SetBinContent(11,0.008634034); TracktoLCTX_5__113->SetBinContent(12,0.008325676); TracktoLCTX_5__113->SetBinContent(13,0.007092242); TracktoLCTX_5__113->SetBinContent(14,0.01048418); TracktoLCTX_5__113->SetBinContent(15,0.01002165); TracktoLCTX_5__113->SetBinContent(16,0.005550451); TracktoLCTX_5__113->SetBinContent(17,0.01171762); TracktoLCTX_5__113->SetBinContent(18,0.007092242); TracktoLCTX_5__113->SetBinContent(19,0.01079254); TracktoLCTX_5__113->SetBinContent(20,0.01033001); TracktoLCTX_5__113->SetBinContent(21,0.009867468); TracktoLCTX_5__113->SetBinContent(22,0.01202598); TracktoLCTX_5__113->SetBinContent(23,0.008942392); TracktoLCTX_5__113->SetBinContent(24,0.01171762); TracktoLCTX_5__113->SetBinContent(25,0.01295105); TracktoLCTX_5__113->SetBinContent(26,0.01171762); TracktoLCTX_5__113->SetBinContent(27,0.01264269); TracktoLCTX_5__113->SetBinContent(28,0.01325941); TracktoLCTX_5__113->SetBinContent(29,0.01695971); TracktoLCTX_5__113->SetBinContent(30,0.01510956); TracktoLCTX_5__113->SetBinContent(31,0.01942658); TracktoLCTX_5__113->SetBinContent(32,0.01387613); TracktoLCTX_5__113->SetBinContent(33,0.01942658); TracktoLCTX_5__113->SetBinContent(34,0.02497703); TracktoLCTX_5__113->SetBinContent(35,0.02775225); TracktoLCTX_5__113->SetBinContent(36,0.03021912); TracktoLCTX_5__113->SetBinContent(37,0.03561539); TracktoLCTX_5__113->SetBinContent(38,0.0496457); TracktoLCTX_5__113->SetBinContent(39,0.05874227); TracktoLCTX_5__113->SetBinContent(40,0.07138496); TracktoLCTX_5__113->SetBinContent(41,0.09805796); TracktoLCTX_5__113->SetBinContent(42,0.1487829); TracktoLCTX_5__113->SetBinContent(43,0.2306521); TracktoLCTX_5__113->SetBinContent(44,0.3478282); TracktoLCTX_5__113->SetBinContent(45,0.5999112); TracktoLCTX_5__113->SetBinContent(46,1.067691); TracktoLCTX_5__113->SetBinContent(47,2.142011); TracktoLCTX_5__113->SetBinContent(48,4.841689); TracktoLCTX_5__113->SetBinContent(49,12.14423); TracktoLCTX_5__113->SetBinContent(50,26.05644); TracktoLCTX_5__113->SetBinContent(51,27.31993); TracktoLCTX_5__113->SetBinContent(52,13.45506); TracktoLCTX_5__113->SetBinContent(53,5.234075); TracktoLCTX_5__113->SetBinContent(54,2.302666); TracktoLCTX_5__113->SetBinContent(55,1.15804); TracktoLCTX_5__113->SetBinContent(56,0.6304387); TracktoLCTX_5__113->SetBinContent(57,0.3798975); TracktoLCTX_5__113->SetBinContent(58,0.2247932); TracktoLCTX_5__113->SetBinContent(59,0.141999); TracktoLCTX_5__113->SetBinContent(60,0.115326); TracktoLCTX_5__113->SetBinContent(61,0.08479855); TracktoLCTX_5__113->SetBinContent(62,0.0599757); TracktoLCTX_5__113->SetBinContent(63,0.04764137); TracktoLCTX_5__113->SetBinContent(64,0.04409525); TracktoLCTX_5__113->SetBinContent(65,0.03114419); TracktoLCTX_5__113->SetBinContent(66,0.02790643); TracktoLCTX_5__113->SetBinContent(67,0.02528539); TracktoLCTX_5__113->SetBinContent(68,0.02158509); TracktoLCTX_5__113->SetBinContent(69,0.01464702); TracktoLCTX_5__113->SetBinContent(70,0.01665135); TracktoLCTX_5__113->SetBinContent(71,0.01541792); TracktoLCTX_5__113->SetBinContent(72,0.01418448); TracktoLCTX_5__113->SetBinContent(73,0.01588046); TracktoLCTX_5__113->SetBinContent(74,0.01233433); TracktoLCTX_5__113->SetBinContent(75,0.01387613); TracktoLCTX_5__113->SetBinContent(76,0.01233433); TracktoLCTX_5__113->SetBinContent(77,0.0111009); TracktoLCTX_5__113->SetBinContent(78,0.01171762); TracktoLCTX_5__113->SetBinContent(79,0.01202598); TracktoLCTX_5__113->SetBinContent(80,0.01218016); TracktoLCTX_5__113->SetBinContent(81,0.01202598); TracktoLCTX_5__113->SetBinContent(82,0.01048418); TracktoLCTX_5__113->SetBinContent(83,0.01310523); TracktoLCTX_5__113->SetBinContent(84,0.01171762); TracktoLCTX_5__113->SetBinContent(85,0.009559109); TracktoLCTX_5__113->SetBinContent(86,0.01171762); TracktoLCTX_5__113->SetBinContent(87,0.01017583); TracktoLCTX_5__113->SetBinContent(88,0.01048418); TracktoLCTX_5__113->SetBinContent(89,0.01140926); TracktoLCTX_5__113->SetBinContent(90,0.01048418); TracktoLCTX_5__113->SetBinContent(91,0.01387613); TracktoLCTX_5__113->SetBinContent(92,0.01079254); TracktoLCTX_5__113->SetBinContent(93,0.009250751); TracktoLCTX_5__113->SetBinContent(94,0.009867468); TracktoLCTX_5__113->SetBinContent(95,0.009250751); TracktoLCTX_5__113->SetBinContent(96,0.008634034); TracktoLCTX_5__113->SetBinContent(97,0.007708959); TracktoLCTX_5__113->SetBinContent(98,0.009250751); TracktoLCTX_5__113->SetBinContent(99,0.008017317); TracktoLCTX_5__113->SetBinContent(100,0.006475526); TracktoLCTX_5__113->SetBinContent(101,0.1988911); TracktoLCTX_5__113->SetEntries(1678146); TracktoLCTX_5__113->SetStats(0); ci = TColor::GetColor("#00ff00"); TracktoLCTX_5__113->SetLineColor(ci); ci = TColor::GetColor("#00ff00"); TracktoLCTX_5__113->SetMarkerColor(ci); TracktoLCTX_5__113->GetXaxis()->SetTitle("cm"); TracktoLCTX_5__113->GetYaxis()->SetTitle("scaled number of entries"); TracktoLCTX_5__113->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("TracktoLCTX_1","ME11A: mean:-0.0cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_2","ME11B: mean:-0.0cm;RMS:4.6cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_3","ME12+13: mean:0.0cm;RMS:3.5cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_4","ME2: mean:0.0cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_5","ME3: mean:0.1cm;RMS:2.8cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_6","ME4: mean:0.0cm;RMS:2.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TH1D *TracktoLCTX_6__114 = new TH1D("TracktoLCTX_6__114","TracktoLCTX",100,-40,40); TracktoLCTX_6__114->SetBinContent(0,132.1923); TracktoLCTX_6__114->SetBinContent(1,0.001398638); TracktoLCTX_6__114->SetBinContent(2,0.003146936); TracktoLCTX_6__114->SetBinContent(3,0.004895233); TracktoLCTX_6__114->SetBinContent(4,0.004895233); TracktoLCTX_6__114->SetBinContent(5,0.003846255); TracktoLCTX_6__114->SetBinContent(6,0.005944212); TracktoLCTX_6__114->SetBinContent(7,0.003496595); TracktoLCTX_6__114->SetBinContent(8,0.004195914); TracktoLCTX_6__114->SetBinContent(9,0.003846255); TracktoLCTX_6__114->SetBinContent(10,0.005944212); TracktoLCTX_6__114->SetBinContent(11,0.003146936); TracktoLCTX_6__114->SetBinContent(12,0.00716802); TracktoLCTX_6__114->SetBinContent(13,0.003146936); TracktoLCTX_6__114->SetBinContent(14,0.002097957); TracktoLCTX_6__114->SetBinContent(15,0.003496595); TracktoLCTX_6__114->SetBinContent(16,0.005594552); TracktoLCTX_6__114->SetBinContent(17,0.003846255); TracktoLCTX_6__114->SetBinContent(18,0.003496595); TracktoLCTX_6__114->SetBinContent(19,0.004895233); TracktoLCTX_6__114->SetBinContent(20,0.005244893); TracktoLCTX_6__114->SetBinContent(21,0.00699319); TracktoLCTX_6__114->SetBinContent(22,0.005244893); TracktoLCTX_6__114->SetBinContent(23,0.009091147); TracktoLCTX_6__114->SetBinContent(24,0.008042169); TracktoLCTX_6__114->SetBinContent(25,0.008042169); TracktoLCTX_6__114->SetBinContent(26,0.00734285); TracktoLCTX_6__114->SetBinContent(27,0.009790467); TracktoLCTX_6__114->SetBinContent(28,0.006293871); TracktoLCTX_6__114->SetBinContent(29,0.007692509); TracktoLCTX_6__114->SetBinContent(30,0.007692509); TracktoLCTX_6__114->SetBinContent(31,0.01014013); TracktoLCTX_6__114->SetBinContent(32,0.01363672); TracktoLCTX_6__114->SetBinContent(33,0.01958093); TracktoLCTX_6__114->SetBinContent(34,0.01538502); TracktoLCTX_6__114->SetBinContent(35,0.02132923); TracktoLCTX_6__114->SetBinContent(36,0.02377685); TracktoLCTX_6__114->SetBinContent(37,0.0293714); TracktoLCTX_6__114->SetBinContent(38,0.03356731); TracktoLCTX_6__114->SetBinContent(39,0.05209927); TracktoLCTX_6__114->SetBinContent(40,0.07884822); TracktoLCTX_6__114->SetBinContent(41,0.09003733); TracktoLCTX_6__114->SetBinContent(42,0.1477311); TracktoLCTX_6__114->SetBinContent(43,0.2288522); TracktoLCTX_6__114->SetBinContent(44,0.3765833); TracktoLCTX_6__114->SetBinContent(45,0.6750177); TracktoLCTX_6__114->SetBinContent(46,1.234298); TracktoLCTX_6__114->SetBinContent(47,2.558634); TracktoLCTX_6__114->SetBinContent(48,5.579692); TracktoLCTX_6__114->SetBinContent(49,12.90051); TracktoLCTX_6__114->SetBinContent(50,24.16759); TracktoLCTX_6__114->SetBinContent(51,25.31535); TracktoLCTX_6__114->SetBinContent(52,14.24845); TracktoLCTX_6__114->SetBinContent(53,6.09002); TracktoLCTX_6__114->SetBinContent(54,2.648846); TracktoLCTX_6__114->SetBinContent(55,1.29409); TracktoLCTX_6__114->SetBinContent(56,0.6807871); TracktoLCTX_6__114->SetBinContent(57,0.3872479); TracktoLCTX_6__114->SetBinContent(58,0.2234324); TracktoLCTX_6__114->SetBinContent(59,0.1461577); TracktoLCTX_6__114->SetBinContent(60,0.1010516); TracktoLCTX_6__114->SetBinContent(61,0.0699319); TracktoLCTX_6__114->SetBinContent(62,0.04615506); TracktoLCTX_6__114->SetBinContent(63,0.03846255); TracktoLCTX_6__114->SetBinContent(64,0.02412651); TracktoLCTX_6__114->SetBinContent(65,0.02500066); TracktoLCTX_6__114->SetBinContent(66,0.01818229); TracktoLCTX_6__114->SetBinContent(67,0.01678366); TracktoLCTX_6__114->SetBinContent(68,0.01958093); TracktoLCTX_6__114->SetBinContent(69,0.01398638); TracktoLCTX_6__114->SetBinContent(70,0.01258774); TracktoLCTX_6__114->SetBinContent(71,0.01153876); TracktoLCTX_6__114->SetBinContent(72,0.00734285); TracktoLCTX_6__114->SetBinContent(73,0.01014013); TracktoLCTX_6__114->SetBinContent(74,0.01048979); TracktoLCTX_6__114->SetBinContent(75,0.00751768); TracktoLCTX_6__114->SetBinContent(76,0.005594552); TracktoLCTX_6__114->SetBinContent(77,0.01014013); TracktoLCTX_6__114->SetBinContent(78,0.006643531); TracktoLCTX_6__114->SetBinContent(79,0.005244893); TracktoLCTX_6__114->SetBinContent(80,0.004720404); TracktoLCTX_6__114->SetBinContent(81,0.008391828); TracktoLCTX_6__114->SetBinContent(82,0.005944212); TracktoLCTX_6__114->SetBinContent(83,0.005769382); TracktoLCTX_6__114->SetBinContent(84,0.002097957); TracktoLCTX_6__114->SetBinContent(85,0.003146936); TracktoLCTX_6__114->SetBinContent(86,0.004545574); TracktoLCTX_6__114->SetBinContent(87,0.005244893); TracktoLCTX_6__114->SetBinContent(88,0.003846255); TracktoLCTX_6__114->SetBinContent(89,0.004895233); TracktoLCTX_6__114->SetBinContent(90,0.003496595); TracktoLCTX_6__114->SetBinContent(91,0.005944212); TracktoLCTX_6__114->SetBinContent(92,0.003146936); TracktoLCTX_6__114->SetBinContent(93,0.005594552); TracktoLCTX_6__114->SetBinContent(94,0.001748298); TracktoLCTX_6__114->SetBinContent(95,0.002797276); TracktoLCTX_6__114->SetBinContent(96,0.004895233); TracktoLCTX_6__114->SetBinContent(97,0.003146936); TracktoLCTX_6__114->SetBinContent(98,0.002097957); TracktoLCTX_6__114->SetBinContent(99,0.003846255); TracktoLCTX_6__114->SetBinContent(100,0.003146936); TracktoLCTX_6__114->SetBinContent(101,0.06888293); TracktoLCTX_6__114->SetEntries(1328499); TracktoLCTX_6__114->SetStats(0); ci = TColor::GetColor("#0000ff"); TracktoLCTX_6__114->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); TracktoLCTX_6__114->SetMarkerColor(ci); TracktoLCTX_6__114->GetXaxis()->SetTitle("cm"); TracktoLCTX_6__114->GetYaxis()->SetTitle("scaled number of entries"); TracktoLCTX_6__114->Draw("H,same"); leg = new TLegend(0.5,0.7,0.9,0.9,NULL,"brNDC"); leg->SetBorderSize(1); leg->SetTextFont(62); leg->SetTextSize(0.02); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(1); leg->SetFillColor(0); leg->SetFillStyle(1001); entry=leg->AddEntry("TracktoLCTX_1","ME11A: mean:-0.0cm;RMS:4.7cm","l"); ci = TColor::GetColor("#ff00ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_2","ME11B: mean:-0.0cm;RMS:4.6cm","l"); ci = TColor::GetColor("#ff9999"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_3","ME12+13: mean:0.0cm;RMS:3.5cm","l"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_4","ME2: mean:0.0cm;RMS:4.0cm","l"); ci = TColor::GetColor("#ff0000"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_5","ME3: mean:0.1cm;RMS:2.8cm","l"); ci = TColor::GetColor("#00ff00"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); entry=leg->AddEntry("TracktoLCTX_6","ME4: mean:0.0cm;RMS:2.3cm","l"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(62); leg->Draw(); TPaveText *pt = new TPaveText(0.01,0.945,0.3062097,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(1); pt->SetFillColor(0); TText *AText = pt->AddText("TracktoLCTX"); pt->Draw(); TracktoLCTX->Modified(); TracktoLCTX->cd(); TracktoLCTX->SetSelected(TracktoLCTX); }
void single() { //=========Macro generated from canvas: METODO2/Simulazione MC (1000 simulazioni) - Likelihood //========= (Fri Dec 30 16:48:29 2016) by ROOT version6.09/01 TCanvas *METODO2 = new TCanvas("METODO2", "Simulazione MC (1000 simulazioni) - Likelihood",97,58,1202,813); gStyle->SetOptStat(0); METODO2->SetHighLightColor(2); METODO2->Range(0,0,1,1); METODO2->SetFillColor(0); METODO2->SetBorderMode(0); METODO2->SetBorderSize(2); METODO2->SetFrameBorderMode(0); // ------------>Primitives in pad: METODO2_1 TPad *METODO2_1 = new TPad("METODO2_1", "METODO2_1",0.01,0.51,0.24,0.99); METODO2_1->Draw(); METODO2_1->cd(); METODO2_1->Range(2.073257,-7.875001,2.385795,70.875); METODO2_1->SetFillColor(0); METODO2_1->SetBorderMode(0); METODO2_1->SetBorderSize(2); METODO2_1->SetFrameBorderMode(0); METODO2_1->SetFrameBorderMode(0); TH1D *hFitTauL2__9__1 = new TH1D("hFitTauL2__9__1","#tau_{+}",40,2.104511,2.354541); hFitTauL2__9__1->SetBinContent(1,3); hFitTauL2__9__1->SetBinContent(2,5); hFitTauL2__9__1->SetBinContent(3,8); hFitTauL2__9__1->SetBinContent(4,12); hFitTauL2__9__1->SetBinContent(5,11); hFitTauL2__9__1->SetBinContent(6,33); hFitTauL2__9__1->SetBinContent(7,38); hFitTauL2__9__1->SetBinContent(8,31); hFitTauL2__9__1->SetBinContent(9,41); hFitTauL2__9__1->SetBinContent(10,46); hFitTauL2__9__1->SetBinContent(11,55); hFitTauL2__9__1->SetBinContent(12,49); hFitTauL2__9__1->SetBinContent(13,48); hFitTauL2__9__1->SetBinContent(14,60); hFitTauL2__9__1->SetBinContent(15,58); hFitTauL2__9__1->SetBinContent(16,59); hFitTauL2__9__1->SetBinContent(17,45); hFitTauL2__9__1->SetBinContent(18,48); hFitTauL2__9__1->SetBinContent(19,38); hFitTauL2__9__1->SetBinContent(20,34); hFitTauL2__9__1->SetBinContent(21,37); hFitTauL2__9__1->SetBinContent(22,40); hFitTauL2__9__1->SetBinContent(23,34); hFitTauL2__9__1->SetBinContent(24,26); hFitTauL2__9__1->SetBinContent(25,26); hFitTauL2__9__1->SetBinContent(26,17); hFitTauL2__9__1->SetBinContent(27,25); hFitTauL2__9__1->SetBinContent(28,13); hFitTauL2__9__1->SetBinContent(29,12); hFitTauL2__9__1->SetBinContent(30,6); hFitTauL2__9__1->SetBinContent(31,5); hFitTauL2__9__1->SetBinContent(32,2); hFitTauL2__9__1->SetBinContent(33,2); hFitTauL2__9__1->SetBinContent(34,1); hFitTauL2__9__1->SetBinContent(37,1); hFitTauL2__9__1->SetEntries(969); hFitTauL2__9__1->SetStats(0); TF1 *gaus1 = new TF1("gaus","gaus",2.107636,2.351416); gaus1->SetFillColor(19); gaus1->SetFillStyle(0); gaus1->SetLineColor(2); gaus1->SetLineWidth(2); gaus1->SetChisquare(40.40096); gaus1->SetNDF(32); gaus1->GetXaxis()->SetLabelFont(42); gaus1->GetXaxis()->SetLabelSize(0.035); gaus1->GetXaxis()->SetTitleSize(0.035); gaus1->GetXaxis()->SetTitleFont(42); gaus1->GetYaxis()->SetLabelFont(42); gaus1->GetYaxis()->SetLabelSize(0.035); gaus1->GetYaxis()->SetTitleSize(0.035); gaus1->GetYaxis()->SetTitleFont(42); gaus1->SetParameter(0,55.14361); gaus1->SetParError(0,2.225785); gaus1->SetParLimits(0,0,0); gaus1->SetParameter(1,2.19903); gaus1->SetParError(1,0.001480435); gaus1->SetParLimits(1,0,0); gaus1->SetParameter(2,0.04266168); gaus1->SetParError(2,0.001105597); gaus1->SetParLimits(2,0,0.4145804); hFitTauL2__9__1->GetListOfFunctions()->Add(gaus1); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#000099"); hFitTauL2__9__1->SetLineColor(ci); hFitTauL2__9__1->GetXaxis()->SetTitle("mus"); hFitTauL2__9__1->GetXaxis()->CenterTitle(true); hFitTauL2__9__1->GetXaxis()->SetNdivisions(505); hFitTauL2__9__1->GetXaxis()->SetLabelFont(42); hFitTauL2__9__1->GetXaxis()->SetLabelOffset(-0.005); hFitTauL2__9__1->GetXaxis()->SetLabelSize(0.07); hFitTauL2__9__1->GetXaxis()->SetTitleSize(0.07); hFitTauL2__9__1->GetXaxis()->SetTitleOffset(0.7); hFitTauL2__9__1->GetXaxis()->SetTitleFont(42); hFitTauL2__9__1->GetYaxis()->SetNdivisions(506); hFitTauL2__9__1->GetYaxis()->SetLabelFont(42); hFitTauL2__9__1->GetYaxis()->SetLabelSize(0.07); hFitTauL2__9__1->GetYaxis()->SetTitleSize(0.035); hFitTauL2__9__1->GetYaxis()->SetTitleFont(42); hFitTauL2__9__1->GetZaxis()->SetLabelFont(42); hFitTauL2__9__1->GetZaxis()->SetLabelSize(0.035); hFitTauL2__9__1->GetZaxis()->SetTitleSize(0.035); hFitTauL2__9__1->GetZaxis()->SetTitleFont(42); hFitTauL2__9__1->Draw(""); TLine *line = new TLine(2.197175,0,2.197175,60); ci = TColor::GetColor("#006600"); line->SetLineColor(ci); line->SetLineWidth(3); line->Draw(); TPaveText *pt = new TPaveText(0.4700392,0.94,0.5299608,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); pt->SetTextSize(0.1009779); TText *AText = pt->AddText("#tau_{+}"); pt->Draw(); METODO2_1->Modified(); METODO2->cd(); // ------------>Primitives in pad: METODO2_2 TPad *METODO2_2 = new TPad("METODO2_2", "METODO2_2",0.26,0.51,0.49,0.99); METODO2_2->Draw(); METODO2_2->cd(); METODO2_2->Range(0.7088825,-8.793751,1.086034,79.14375); METODO2_2->SetFillColor(0); METODO2_2->SetBorderMode(0); METODO2_2->SetBorderSize(2); METODO2_2->SetFrameBorderMode(0); METODO2_2->SetFrameBorderMode(0); TH1D *hFitTauShortL2__10__2 = new TH1D("hFitTauShortL2__10__2","#tau_{-}",40,0.7465977,1.048319); hFitTauShortL2__10__2->SetBinContent(1,2); hFitTauShortL2__10__2->SetBinContent(2,6); hFitTauShortL2__10__2->SetBinContent(3,8); hFitTauShortL2__10__2->SetBinContent(4,11); hFitTauShortL2__10__2->SetBinContent(5,12); hFitTauShortL2__10__2->SetBinContent(6,15); hFitTauShortL2__10__2->SetBinContent(7,20); hFitTauShortL2__10__2->SetBinContent(8,28); hFitTauShortL2__10__2->SetBinContent(9,21); hFitTauShortL2__10__2->SetBinContent(10,32); hFitTauShortL2__10__2->SetBinContent(11,30); hFitTauShortL2__10__2->SetBinContent(12,35); hFitTauShortL2__10__2->SetBinContent(13,32); hFitTauShortL2__10__2->SetBinContent(14,46); hFitTauShortL2__10__2->SetBinContent(15,49); hFitTauShortL2__10__2->SetBinContent(16,41); hFitTauShortL2__10__2->SetBinContent(17,50); hFitTauShortL2__10__2->SetBinContent(18,67); hFitTauShortL2__10__2->SetBinContent(19,50); hFitTauShortL2__10__2->SetBinContent(20,40); hFitTauShortL2__10__2->SetBinContent(21,42); hFitTauShortL2__10__2->SetBinContent(22,51); hFitTauShortL2__10__2->SetBinContent(23,36); hFitTauShortL2__10__2->SetBinContent(24,48); hFitTauShortL2__10__2->SetBinContent(25,37); hFitTauShortL2__10__2->SetBinContent(26,26); hFitTauShortL2__10__2->SetBinContent(27,26); hFitTauShortL2__10__2->SetBinContent(28,26); hFitTauShortL2__10__2->SetBinContent(29,23); hFitTauShortL2__10__2->SetBinContent(30,13); hFitTauShortL2__10__2->SetBinContent(31,6); hFitTauShortL2__10__2->SetBinContent(32,9); hFitTauShortL2__10__2->SetBinContent(33,9); hFitTauShortL2__10__2->SetBinContent(34,12); hFitTauShortL2__10__2->SetBinContent(35,2); hFitTauShortL2__10__2->SetBinContent(36,3); hFitTauShortL2__10__2->SetBinContent(37,1); hFitTauShortL2__10__2->SetBinContent(38,3); hFitTauShortL2__10__2->SetBinContent(39,1); hFitTauShortL2__10__2->SetEntries(969); hFitTauShortL2__10__2->SetStats(0); TF1 *gaus2 = new TF1("gaus","gaus",0.7503692,1.044548); gaus2->SetFillColor(19); gaus2->SetFillStyle(0); gaus2->SetLineColor(2); gaus2->SetLineWidth(2); gaus2->SetChisquare(36.70305); gaus2->SetNDF(36); gaus2->GetXaxis()->SetLabelFont(42); gaus2->GetXaxis()->SetLabelSize(0.035); gaus2->GetXaxis()->SetTitleSize(0.035); gaus2->GetXaxis()->SetTitleFont(42); gaus2->GetYaxis()->SetLabelFont(42); gaus2->GetYaxis()->SetLabelSize(0.035); gaus2->GetYaxis()->SetTitleSize(0.035); gaus2->GetYaxis()->SetTitleFont(42); gaus2->SetParameter(0,50.39287); gaus2->SetParError(0,2.049464); gaus2->SetParLimits(0,0,0); gaus2->SetParameter(1,0.8784985); gaus2->SetParError(1,0.001946827); gaus2->SetParLimits(1,0,0); gaus2->SetParameter(2,0.05632111); gaus2->SetParError(2,0.001480131); gaus2->SetParLimits(2,0,0.554472); hFitTauShortL2__10__2->GetListOfFunctions()->Add(gaus2); ci = TColor::GetColor("#000099"); hFitTauShortL2__10__2->SetLineColor(ci); hFitTauShortL2__10__2->GetXaxis()->SetTitle("mus"); hFitTauShortL2__10__2->GetXaxis()->CenterTitle(true); hFitTauShortL2__10__2->GetXaxis()->SetNdivisions(506); hFitTauShortL2__10__2->GetXaxis()->SetLabelFont(42); hFitTauShortL2__10__2->GetXaxis()->SetLabelOffset(-0.005); hFitTauShortL2__10__2->GetXaxis()->SetLabelSize(0.07); hFitTauShortL2__10__2->GetXaxis()->SetTitleSize(0.07); hFitTauShortL2__10__2->GetXaxis()->SetTitleOffset(0.7); hFitTauShortL2__10__2->GetXaxis()->SetTitleFont(42); hFitTauShortL2__10__2->GetYaxis()->SetNdivisions(507); hFitTauShortL2__10__2->GetYaxis()->SetLabelFont(42); hFitTauShortL2__10__2->GetYaxis()->SetLabelSize(0.07); hFitTauShortL2__10__2->GetYaxis()->SetTitleSize(0.035); hFitTauShortL2__10__2->GetYaxis()->SetTitleFont(42); hFitTauShortL2__10__2->GetZaxis()->SetLabelFont(42); hFitTauShortL2__10__2->GetZaxis()->SetLabelSize(0.035); hFitTauShortL2__10__2->GetZaxis()->SetTitleSize(0.035); hFitTauShortL2__10__2->GetZaxis()->SetTitleFont(42); hFitTauShortL2__10__2->Draw(""); line = new TLine(0.8809186,0,0.8809186,67); ci = TColor::GetColor("#006600"); line->SetLineColor(ci); line->SetLineWidth(3); line->Draw(); pt = new TPaveText(0.4754831,0.94,0.5245169,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); pt->SetTextSize(0.1009779); AText = pt->AddText("#tau_{-}"); pt->Draw(); METODO2_2->Modified(); METODO2->cd(); // ------------>Primitives in pad: METODO2_3 TPad *METODO2_3 = new TPad("METODO2_3", "METODO2_3",0.51,0.51,0.74,0.99); METODO2_3->Draw(); METODO2_3->cd(); METODO2_3->Range(0.8959783,-9.318751,1.111001,83.86875); METODO2_3->SetFillColor(0); METODO2_3->SetBorderMode(0); METODO2_3->SetBorderSize(2); METODO2_3->SetFrameBorderMode(0); METODO2_3->SetFrameBorderMode(0); TH1D *hFitBL2__11__3 = new TH1D("hFitBL2__11__3","b",40,0.9174806,1.089499); hFitBL2__11__3->SetBinContent(1,2); hFitBL2__11__3->SetBinContent(2,1); hFitBL2__11__3->SetBinContent(3,2); hFitBL2__11__3->SetBinContent(4,4); hFitBL2__11__3->SetBinContent(5,2); hFitBL2__11__3->SetBinContent(6,3); hFitBL2__11__3->SetBinContent(7,6); hFitBL2__11__3->SetBinContent(8,9); hFitBL2__11__3->SetBinContent(9,15); hFitBL2__11__3->SetBinContent(10,13); hFitBL2__11__3->SetBinContent(11,27); hFitBL2__11__3->SetBinContent(12,25); hFitBL2__11__3->SetBinContent(13,33); hFitBL2__11__3->SetBinContent(14,51); hFitBL2__11__3->SetBinContent(15,40); hFitBL2__11__3->SetBinContent(16,68); hFitBL2__11__3->SetBinContent(17,48); hFitBL2__11__3->SetBinContent(18,59); hFitBL2__11__3->SetBinContent(19,56); hFitBL2__11__3->SetBinContent(20,56); hFitBL2__11__3->SetBinContent(21,71); hFitBL2__11__3->SetBinContent(22,63); hFitBL2__11__3->SetBinContent(23,51); hFitBL2__11__3->SetBinContent(24,38); hFitBL2__11__3->SetBinContent(25,47); hFitBL2__11__3->SetBinContent(26,39); hFitBL2__11__3->SetBinContent(27,37); hFitBL2__11__3->SetBinContent(28,29); hFitBL2__11__3->SetBinContent(29,18); hFitBL2__11__3->SetBinContent(30,14); hFitBL2__11__3->SetBinContent(31,16); hFitBL2__11__3->SetBinContent(32,10); hFitBL2__11__3->SetBinContent(33,8); hFitBL2__11__3->SetBinContent(34,3); hFitBL2__11__3->SetBinContent(35,2); hFitBL2__11__3->SetBinContent(36,2); hFitBL2__11__3->SetBinContent(38,1); hFitBL2__11__3->SetEntries(969); hFitBL2__11__3->SetStats(0); TF1 *gaus3 = new TF1("gaus","gaus",0.9196308,1.087349); gaus3->SetFillColor(19); gaus3->SetFillStyle(0); gaus3->SetLineColor(2); gaus3->SetLineWidth(2); gaus3->SetChisquare(26.97344); gaus3->SetNDF(34); gaus3->GetXaxis()->SetLabelFont(42); gaus3->GetXaxis()->SetLabelSize(0.035); gaus3->GetXaxis()->SetTitleSize(0.035); gaus3->GetXaxis()->SetTitleFont(42); gaus3->GetYaxis()->SetLabelFont(42); gaus3->GetYaxis()->SetLabelSize(0.035); gaus3->GetYaxis()->SetTitleSize(0.035); gaus3->GetYaxis()->SetTitleFont(42); gaus3->SetParameter(0,61.73503); gaus3->SetParError(0,2.484555); gaus3->SetParLimits(0,0,0); gaus3->SetParameter(1,1.000895); gaus3->SetParError(1,0.0008693081); gaus3->SetParLimits(1,0,0); gaus3->SetParameter(2,0.02626284); gaus3->SetParError(2,0.0006388533); gaus3->SetParLimits(2,0,0.262935); hFitBL2__11__3->GetListOfFunctions()->Add(gaus3); ci = TColor::GetColor("#000099"); hFitBL2__11__3->SetLineColor(ci); hFitBL2__11__3->GetXaxis()->SetTitle("conteggi"); hFitBL2__11__3->GetXaxis()->CenterTitle(true); hFitBL2__11__3->GetXaxis()->SetNdivisions(506); hFitBL2__11__3->GetXaxis()->SetLabelFont(42); hFitBL2__11__3->GetXaxis()->SetLabelOffset(-0.005); hFitBL2__11__3->GetXaxis()->SetLabelSize(0.07); hFitBL2__11__3->GetXaxis()->SetTitleSize(0.07); hFitBL2__11__3->GetXaxis()->SetTitleOffset(0.7); hFitBL2__11__3->GetXaxis()->SetTitleFont(42); hFitBL2__11__3->GetYaxis()->SetNdivisions(507); hFitBL2__11__3->GetYaxis()->SetLabelFont(42); hFitBL2__11__3->GetYaxis()->SetLabelSize(0.07); hFitBL2__11__3->GetYaxis()->SetTitleSize(0.035); hFitBL2__11__3->GetYaxis()->SetTitleFont(42); hFitBL2__11__3->GetZaxis()->SetLabelFont(42); hFitBL2__11__3->GetZaxis()->SetLabelSize(0.035); hFitBL2__11__3->GetZaxis()->SetTitleSize(0.035); hFitBL2__11__3->GetZaxis()->SetTitleFont(42); hFitBL2__11__3->Draw(""); line = new TLine(1,0,1,71); ci = TColor::GetColor("#006600"); line->SetLineColor(ci); line->SetLineWidth(3); line->Draw(); pt = new TPaveText(0.4718538,0.94,0.5208393,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); pt->SetTextSize(0.1009779); AText = pt->AddText("b"); pt->Draw(); METODO2_3->Modified(); METODO2->cd(); // ------------>Primitives in pad: METODO2_4 TPad *METODO2_4 = new TPad("METODO2_4", "METODO2_4",0.76,0.51,0.99,0.99); METODO2_4->Draw(); METODO2_4->cd(); METODO2_4->Range(0.8398416,-8.006251,1.78409,72.05625); METODO2_4->SetFillColor(0); METODO2_4->SetBorderMode(0); METODO2_4->SetBorderSize(2); METODO2_4->SetFrameBorderMode(0); METODO2_4->SetFrameBorderMode(0); TH1D *hFitRL2__12__4 = new TH1D("hFitRL2__12__4","R",40,0.9342664,1.689665); hFitRL2__12__4->SetBinContent(1,4); hFitRL2__12__4->SetBinContent(2,6); hFitRL2__12__4->SetBinContent(3,9); hFitRL2__12__4->SetBinContent(4,12); hFitRL2__12__4->SetBinContent(5,13); hFitRL2__12__4->SetBinContent(6,16); hFitRL2__12__4->SetBinContent(7,21); hFitRL2__12__4->SetBinContent(8,35); hFitRL2__12__4->SetBinContent(9,44); hFitRL2__12__4->SetBinContent(10,31); hFitRL2__12__4->SetBinContent(11,28); hFitRL2__12__4->SetBinContent(12,44); hFitRL2__12__4->SetBinContent(13,36); hFitRL2__12__4->SetBinContent(14,39); hFitRL2__12__4->SetBinContent(15,44); hFitRL2__12__4->SetBinContent(16,45); hFitRL2__12__4->SetBinContent(17,44); hFitRL2__12__4->SetBinContent(18,46); hFitRL2__12__4->SetBinContent(19,61); hFitRL2__12__4->SetBinContent(20,37); hFitRL2__12__4->SetBinContent(21,46); hFitRL2__12__4->SetBinContent(22,41); hFitRL2__12__4->SetBinContent(23,46); hFitRL2__12__4->SetBinContent(24,35); hFitRL2__12__4->SetBinContent(25,31); hFitRL2__12__4->SetBinContent(26,22); hFitRL2__12__4->SetBinContent(27,33); hFitRL2__12__4->SetBinContent(28,25); hFitRL2__12__4->SetBinContent(29,15); hFitRL2__12__4->SetBinContent(30,19); hFitRL2__12__4->SetBinContent(31,11); hFitRL2__12__4->SetBinContent(32,8); hFitRL2__12__4->SetBinContent(33,6); hFitRL2__12__4->SetBinContent(34,5); hFitRL2__12__4->SetBinContent(35,3); hFitRL2__12__4->SetBinContent(36,4); hFitRL2__12__4->SetBinContent(37,1); hFitRL2__12__4->SetBinContent(38,2); hFitRL2__12__4->SetBinContent(40,1); hFitRL2__12__4->SetEntries(969); hFitRL2__12__4->SetStats(0); TF1 *gaus4 = new TF1("gaus","gaus",0.9437089,1.680222); gaus4->SetFillColor(19); gaus4->SetFillStyle(0); gaus4->SetLineColor(2); gaus4->SetLineWidth(2); gaus4->SetChisquare(31.56924); gaus4->SetNDF(36); gaus4->GetXaxis()->SetLabelFont(42); gaus4->GetXaxis()->SetLabelSize(0.035); gaus4->GetXaxis()->SetTitleSize(0.035); gaus4->GetXaxis()->SetTitleFont(42); gaus4->GetYaxis()->SetLabelFont(42); gaus4->GetYaxis()->SetLabelSize(0.035); gaus4->GetYaxis()->SetTitleSize(0.035); gaus4->GetYaxis()->SetTitleFont(42); gaus4->SetParameter(0,48.42124); gaus4->SetParError(0,1.953846); gaus4->SetParLimits(0,0,0); gaus4->SetParameter(1,1.254783); gaus4->SetParError(1,0.005227531); gaus4->SetParLimits(1,0,0); gaus4->SetParameter(2,0.148583); gaus4->SetParError(2,0.003981527); gaus4->SetParLimits(2,0,1.414801); hFitRL2__12__4->GetListOfFunctions()->Add(gaus4); ci = TColor::GetColor("#000099"); hFitRL2__12__4->SetLineColor(ci); hFitRL2__12__4->GetXaxis()->SetNdivisions(507); hFitRL2__12__4->GetXaxis()->SetLabelFont(42); hFitRL2__12__4->GetXaxis()->SetLabelOffset(-0.005); hFitRL2__12__4->GetXaxis()->SetLabelSize(0.07); hFitRL2__12__4->GetXaxis()->SetTitleSize(0.035); hFitRL2__12__4->GetXaxis()->SetTitleFont(42); hFitRL2__12__4->GetYaxis()->SetNdivisions(506); hFitRL2__12__4->GetYaxis()->SetLabelFont(42); hFitRL2__12__4->GetYaxis()->SetLabelSize(0.07); hFitRL2__12__4->GetYaxis()->SetTitleSize(0.035); hFitRL2__12__4->GetYaxis()->SetTitleFont(42); hFitRL2__12__4->GetZaxis()->SetLabelFont(42); hFitRL2__12__4->GetZaxis()->SetLabelSize(0.035); hFitRL2__12__4->GetZaxis()->SetTitleSize(0.035); hFitRL2__12__4->GetZaxis()->SetTitleFont(42); hFitRL2__12__4->Draw(""); line = new TLine(1.261,0,1.261,61); ci = TColor::GetColor("#006600"); line->SetLineColor(ci); line->SetLineWidth(3); line->Draw(); pt = new TPaveText(0.4718538,0.94,0.5281462,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); pt->SetTextSize(0.1009779); AText = pt->AddText("R"); pt->Draw(); METODO2_4->Modified(); METODO2->cd(); // ------------>Primitives in pad: METODO2_5 TPad *METODO2_5 = new TPad("METODO2_5", "METODO2_5",0.01,0.01,0.24,0.49); METODO2_5->Draw(); METODO2_5->cd(); METODO2_5->Range(0.0276943,-8.531251,0.07885156,76.78125); METODO2_5->SetFillColor(0); METODO2_5->SetBorderMode(0); METODO2_5->SetBorderSize(2); METODO2_5->SetFrameBorderMode(0); METODO2_5->SetFrameBorderMode(0); TH1D *hFitErrTauL2__13__5 = new TH1D("hFitErrTauL2__13__5","#tau_{+} - errori",40,0.03281003,0.07373583); hFitErrTauL2__13__5->SetBinContent(1,4); hFitErrTauL2__13__5->SetBinContent(2,14); hFitErrTauL2__13__5->SetBinContent(3,17); hFitErrTauL2__13__5->SetBinContent(4,26); hFitErrTauL2__13__5->SetBinContent(5,37); hFitErrTauL2__13__5->SetBinContent(6,46); hFitErrTauL2__13__5->SetBinContent(7,45); hFitErrTauL2__13__5->SetBinContent(8,49); hFitErrTauL2__13__5->SetBinContent(9,60); hFitErrTauL2__13__5->SetBinContent(10,60); hFitErrTauL2__13__5->SetBinContent(11,65); hFitErrTauL2__13__5->SetBinContent(12,56); hFitErrTauL2__13__5->SetBinContent(13,63); hFitErrTauL2__13__5->SetBinContent(14,54); hFitErrTauL2__13__5->SetBinContent(15,51); hFitErrTauL2__13__5->SetBinContent(16,50); hFitErrTauL2__13__5->SetBinContent(17,49); hFitErrTauL2__13__5->SetBinContent(18,37); hFitErrTauL2__13__5->SetBinContent(19,32); hFitErrTauL2__13__5->SetBinContent(20,34); hFitErrTauL2__13__5->SetBinContent(21,27); hFitErrTauL2__13__5->SetBinContent(22,22); hFitErrTauL2__13__5->SetBinContent(23,19); hFitErrTauL2__13__5->SetBinContent(24,8); hFitErrTauL2__13__5->SetBinContent(25,10); hFitErrTauL2__13__5->SetBinContent(26,7); hFitErrTauL2__13__5->SetBinContent(27,6); hFitErrTauL2__13__5->SetBinContent(28,4); hFitErrTauL2__13__5->SetBinContent(29,3); hFitErrTauL2__13__5->SetBinContent(30,3); hFitErrTauL2__13__5->SetBinContent(31,4); hFitErrTauL2__13__5->SetBinContent(32,1); hFitErrTauL2__13__5->SetBinContent(33,2); hFitErrTauL2__13__5->SetBinContent(34,2); hFitErrTauL2__13__5->SetBinContent(35,1); hFitErrTauL2__13__5->SetBinContent(40,1); hFitErrTauL2__13__5->SetEntries(969); hFitErrTauL2__13__5->SetStats(0); TF1 *gaus5 = new TF1("gaus","gaus",0.03332161,0.07322426); gaus5->SetFillColor(19); gaus5->SetFillStyle(0); gaus5->SetLineColor(2); gaus5->SetLineWidth(2); gaus5->SetChisquare(35.18343); gaus5->SetNDF(33); gaus5->GetXaxis()->SetLabelFont(42); gaus5->GetXaxis()->SetLabelSize(0.035); gaus5->GetXaxis()->SetTitleSize(0.035); gaus5->GetXaxis()->SetTitleFont(42); gaus5->GetYaxis()->SetLabelFont(42); gaus5->GetYaxis()->SetLabelSize(0.035); gaus5->GetYaxis()->SetTitleSize(0.035); gaus5->GetYaxis()->SetTitleFont(42); gaus5->SetParameter(0,61.35917); gaus5->SetParError(0,2.59323); gaus5->SetParLimits(0,0,0); gaus5->SetParameter(1,0.0453134); gaus5->SetParError(1,0.0002230925); gaus5->SetParLimits(1,0,0); gaus5->SetParameter(2,0.006370057); gaus5->SetParError(2,0.0001915713); gaus5->SetParLimits(2,0,0.0639349); hFitErrTauL2__13__5->GetListOfFunctions()->Add(gaus5); ci = TColor::GetColor("#000099"); hFitErrTauL2__13__5->SetLineColor(ci); hFitErrTauL2__13__5->GetXaxis()->SetTitle("mus"); hFitErrTauL2__13__5->GetXaxis()->CenterTitle(true); hFitErrTauL2__13__5->GetXaxis()->SetNdivisions(507); hFitErrTauL2__13__5->GetXaxis()->SetLabelFont(42); hFitErrTauL2__13__5->GetXaxis()->SetLabelOffset(-0.005); hFitErrTauL2__13__5->GetXaxis()->SetLabelSize(0.07); hFitErrTauL2__13__5->GetXaxis()->SetTitleSize(0.07); hFitErrTauL2__13__5->GetXaxis()->SetTitleOffset(0.7); hFitErrTauL2__13__5->GetXaxis()->SetTitleFont(42); hFitErrTauL2__13__5->GetYaxis()->SetNdivisions(506); hFitErrTauL2__13__5->GetYaxis()->SetLabelFont(42); hFitErrTauL2__13__5->GetYaxis()->SetLabelSize(0.07); hFitErrTauL2__13__5->GetYaxis()->SetTitleSize(0.035); hFitErrTauL2__13__5->GetYaxis()->SetTitleFont(42); hFitErrTauL2__13__5->GetZaxis()->SetLabelFont(42); hFitErrTauL2__13__5->GetZaxis()->SetLabelSize(0.035); hFitErrTauL2__13__5->GetZaxis()->SetTitleSize(0.035); hFitErrTauL2__13__5->GetZaxis()->SetTitleFont(42); hFitErrTauL2__13__5->Draw(""); pt = new TPaveText(0.3811229,0.94,0.6188771,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); pt->SetTextSize(0.1009779); AText = pt->AddText("#tau_{+} - errori"); pt->Draw(); METODO2_5->Modified(); METODO2->cd(); // ------------>Primitives in pad: METODO2_6 TPad *METODO2_6 = new TPad("METODO2_6", "METODO2_6",0.26,0.01,0.49,0.49); METODO2_6->Draw(); METODO2_6->cd(); METODO2_6->Range(0.04390291,-10.5,0.08244582,94.5); METODO2_6->SetFillColor(0); METODO2_6->SetBorderMode(0); METODO2_6->SetBorderSize(2); METODO2_6->SetFrameBorderMode(0); METODO2_6->SetFrameBorderMode(0); TH1D *hFitErrTauShortL2__14__6 = new TH1D("hFitErrTauShortL2__14__6","#tau_{-} - errori",40,0.0477572,0.07859153); hFitErrTauShortL2__14__6->SetBinContent(1,1); hFitErrTauShortL2__14__6->SetBinContent(3,2); hFitErrTauShortL2__14__6->SetBinContent(4,2); hFitErrTauShortL2__14__6->SetBinContent(5,7); hFitErrTauShortL2__14__6->SetBinContent(6,12); hFitErrTauShortL2__14__6->SetBinContent(7,16); hFitErrTauShortL2__14__6->SetBinContent(8,12); hFitErrTauShortL2__14__6->SetBinContent(9,27); hFitErrTauShortL2__14__6->SetBinContent(10,35); hFitErrTauShortL2__14__6->SetBinContent(11,46); hFitErrTauShortL2__14__6->SetBinContent(12,52); hFitErrTauShortL2__14__6->SetBinContent(13,56); hFitErrTauShortL2__14__6->SetBinContent(14,61); hFitErrTauShortL2__14__6->SetBinContent(15,80); hFitErrTauShortL2__14__6->SetBinContent(16,59); hFitErrTauShortL2__14__6->SetBinContent(17,66); hFitErrTauShortL2__14__6->SetBinContent(18,57); hFitErrTauShortL2__14__6->SetBinContent(19,63); hFitErrTauShortL2__14__6->SetBinContent(20,61); hFitErrTauShortL2__14__6->SetBinContent(21,55); hFitErrTauShortL2__14__6->SetBinContent(22,48); hFitErrTauShortL2__14__6->SetBinContent(23,30); hFitErrTauShortL2__14__6->SetBinContent(24,28); hFitErrTauShortL2__14__6->SetBinContent(25,16); hFitErrTauShortL2__14__6->SetBinContent(26,16); hFitErrTauShortL2__14__6->SetBinContent(27,19); hFitErrTauShortL2__14__6->SetBinContent(28,8); hFitErrTauShortL2__14__6->SetBinContent(29,5); hFitErrTauShortL2__14__6->SetBinContent(30,6); hFitErrTauShortL2__14__6->SetBinContent(31,4); hFitErrTauShortL2__14__6->SetBinContent(32,4); hFitErrTauShortL2__14__6->SetBinContent(33,5); hFitErrTauShortL2__14__6->SetBinContent(34,4); hFitErrTauShortL2__14__6->SetBinContent(35,2); hFitErrTauShortL2__14__6->SetBinContent(36,1); hFitErrTauShortL2__14__6->SetBinContent(37,1); hFitErrTauShortL2__14__6->SetBinContent(39,2); hFitErrTauShortL2__14__6->SetEntries(969); hFitErrTauShortL2__14__6->SetStats(0); TF1 *gaus6 = new TF1("gaus","gaus",0.04814263,0.0782061); gaus6->SetFillColor(19); gaus6->SetFillStyle(0); gaus6->SetLineColor(2); gaus6->SetLineWidth(2); gaus6->SetChisquare(38.01385); gaus6->SetNDF(34); gaus6->GetXaxis()->SetLabelFont(42); gaus6->GetXaxis()->SetLabelSize(0.035); gaus6->GetXaxis()->SetTitleSize(0.035); gaus6->GetXaxis()->SetTitleFont(42); gaus6->GetYaxis()->SetLabelFont(42); gaus6->GetYaxis()->SetLabelSize(0.035); gaus6->GetYaxis()->SetTitleSize(0.035); gaus6->GetYaxis()->SetTitleFont(42); gaus6->SetParameter(0,68.18906); gaus6->SetParError(0,2.855854); gaus6->SetParLimits(0,0,0); gaus6->SetParameter(1,0.06034312); gaus6->SetParError(1,0.000142911); gaus6->SetParLimits(1,0,0); gaus6->SetParameter(2,0.004212504); gaus6->SetParError(2,0.0001124842); gaus6->SetParLimits(2,0,0.04501277); hFitErrTauShortL2__14__6->GetListOfFunctions()->Add(gaus6); ci = TColor::GetColor("#000099"); hFitErrTauShortL2__14__6->SetLineColor(ci); hFitErrTauShortL2__14__6->GetXaxis()->SetTitle("mus"); hFitErrTauShortL2__14__6->GetXaxis()->CenterTitle(true); hFitErrTauShortL2__14__6->GetXaxis()->SetNdivisions(506); hFitErrTauShortL2__14__6->GetXaxis()->SetLabelFont(42); hFitErrTauShortL2__14__6->GetXaxis()->SetLabelOffset(-0.005); hFitErrTauShortL2__14__6->GetXaxis()->SetLabelSize(0.07); hFitErrTauShortL2__14__6->GetXaxis()->SetTitleSize(0.07); hFitErrTauShortL2__14__6->GetXaxis()->SetTitleOffset(0.7); hFitErrTauShortL2__14__6->GetXaxis()->SetTitleFont(42); hFitErrTauShortL2__14__6->GetYaxis()->SetNdivisions(507); hFitErrTauShortL2__14__6->GetYaxis()->SetLabelFont(42); hFitErrTauShortL2__14__6->GetYaxis()->SetLabelSize(0.07); hFitErrTauShortL2__14__6->GetYaxis()->SetTitleSize(0.035); hFitErrTauShortL2__14__6->GetYaxis()->SetTitleFont(42); hFitErrTauShortL2__14__6->GetZaxis()->SetLabelFont(42); hFitErrTauShortL2__14__6->GetZaxis()->SetLabelSize(0.035); hFitErrTauShortL2__14__6->GetZaxis()->SetTitleSize(0.035); hFitErrTauShortL2__14__6->GetZaxis()->SetTitleFont(42); hFitErrTauShortL2__14__6->Draw(""); pt = new TPaveText(0.3865667,0.94,0.6134333,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); pt->SetTextSize(0.1009779); AText = pt->AddText("#tau_{-} - errori"); pt->Draw(); METODO2_6->Modified(); METODO2->cd(); // ------------>Primitives in pad: METODO2_7 TPad *METODO2_7 = new TPad("METODO2_7", "METODO2_7",0.51,0.01,0.74,0.49); METODO2_7->Draw(); METODO2_7->cd(); METODO2_7->Range(0.02895023,-10.2375,0.03645069,92.1375); METODO2_7->SetFillColor(0); METODO2_7->SetBorderMode(0); METODO2_7->SetBorderSize(2); METODO2_7->SetFrameBorderMode(0); METODO2_7->SetFrameBorderMode(0); TH1D *hFitErrBL2__15__7 = new TH1D("hFitErrBL2__15__7","B - errori",40,0.02970028,0.03570064); hFitErrBL2__15__7->SetBinContent(1,6); hFitErrBL2__15__7->SetBinContent(2,5); hFitErrBL2__15__7->SetBinContent(3,10); hFitErrBL2__15__7->SetBinContent(4,15); hFitErrBL2__15__7->SetBinContent(5,22); hFitErrBL2__15__7->SetBinContent(6,36); hFitErrBL2__15__7->SetBinContent(7,43); hFitErrBL2__15__7->SetBinContent(8,50); hFitErrBL2__15__7->SetBinContent(9,65); hFitErrBL2__15__7->SetBinContent(10,60); hFitErrBL2__15__7->SetBinContent(11,78); hFitErrBL2__15__7->SetBinContent(12,68); hFitErrBL2__15__7->SetBinContent(13,61); hFitErrBL2__15__7->SetBinContent(14,52); hFitErrBL2__15__7->SetBinContent(15,73); hFitErrBL2__15__7->SetBinContent(16,50); hFitErrBL2__15__7->SetBinContent(17,56); hFitErrBL2__15__7->SetBinContent(18,48); hFitErrBL2__15__7->SetBinContent(19,31); hFitErrBL2__15__7->SetBinContent(20,29); hFitErrBL2__15__7->SetBinContent(21,22); hFitErrBL2__15__7->SetBinContent(22,24); hFitErrBL2__15__7->SetBinContent(23,18); hFitErrBL2__15__7->SetBinContent(24,13); hFitErrBL2__15__7->SetBinContent(25,13); hFitErrBL2__15__7->SetBinContent(26,3); hFitErrBL2__15__7->SetBinContent(27,6); hFitErrBL2__15__7->SetBinContent(28,1); hFitErrBL2__15__7->SetBinContent(29,4); hFitErrBL2__15__7->SetBinContent(30,2); hFitErrBL2__15__7->SetBinContent(32,1); hFitErrBL2__15__7->SetBinContent(35,1); hFitErrBL2__15__7->SetBinContent(38,3); hFitErrBL2__15__7->SetEntries(969); hFitErrBL2__15__7->SetStats(0); TF1 *gaus7 = new TF1("gaus","gaus",0.02977528,0.03562564); gaus7->SetFillColor(19); gaus7->SetFillStyle(0); gaus7->SetLineColor(2); gaus7->SetLineWidth(2); gaus7->SetChisquare(39.93834); gaus7->SetNDF(30); gaus7->GetXaxis()->SetLabelFont(42); gaus7->GetXaxis()->SetLabelSize(0.035); gaus7->GetXaxis()->SetTitleSize(0.035); gaus7->GetXaxis()->SetTitleFont(42); gaus7->GetYaxis()->SetLabelFont(42); gaus7->GetYaxis()->SetLabelSize(0.035); gaus7->GetYaxis()->SetTitleSize(0.035); gaus7->GetYaxis()->SetTitleFont(42); gaus7->SetParameter(0,67.73498); gaus7->SetParError(0,2.8055); gaus7->SetParLimits(0,0,0); gaus7->SetParameter(1,0.03159294); gaus7->SetParError(1,2.852494e-05); gaus7->SetParLimits(1,0,0); gaus7->SetParameter(2,0.0008306818); gaus7->SetParError(2,2.25768e-05); gaus7->SetParLimits(2,0,0.008572887); hFitErrBL2__15__7->GetListOfFunctions()->Add(gaus7); ci = TColor::GetColor("#000099"); hFitErrBL2__15__7->SetLineColor(ci); hFitErrBL2__15__7->GetXaxis()->SetTitle("conteggi"); hFitErrBL2__15__7->GetXaxis()->CenterTitle(true); hFitErrBL2__15__7->GetXaxis()->SetNdivisions(506); hFitErrBL2__15__7->GetXaxis()->SetLabelFont(42); hFitErrBL2__15__7->GetXaxis()->SetLabelOffset(-0.005); hFitErrBL2__15__7->GetXaxis()->SetLabelSize(0.07); hFitErrBL2__15__7->GetXaxis()->SetTitleSize(0.07); hFitErrBL2__15__7->GetXaxis()->SetTitleOffset(0.7); hFitErrBL2__15__7->GetXaxis()->SetTitleFont(42); hFitErrBL2__15__7->GetYaxis()->SetNdivisions(507); hFitErrBL2__15__7->GetYaxis()->SetLabelFont(42); hFitErrBL2__15__7->GetYaxis()->SetLabelSize(0.07); hFitErrBL2__15__7->GetYaxis()->SetTitleSize(0.035); hFitErrBL2__15__7->GetYaxis()->SetTitleFont(42); hFitErrBL2__15__7->GetZaxis()->SetLabelFont(42); hFitErrBL2__15__7->GetZaxis()->SetLabelSize(0.035); hFitErrBL2__15__7->GetZaxis()->SetTitleSize(0.035); hFitErrBL2__15__7->GetZaxis()->SetTitleFont(42); hFitErrBL2__15__7->Draw(""); pt = new TPaveText(0.3829375,0.94,0.6170625,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); pt->SetTextSize(0.1009779); AText = pt->AddText("B - errori"); pt->Draw(); METODO2_7->Modified(); METODO2->cd(); // ------------>Primitives in pad: METODO2_8 TPad *METODO2_8 = new TPad("METODO2_8", "METODO2_8",0.76,0.01,0.99,0.49); METODO2_8->Draw(); METODO2_8->cd(); METODO2_8->Range(0.07309322,-10.89375,0.1870743,98.04375); METODO2_8->SetFillColor(0); METODO2_8->SetBorderMode(0); METODO2_8->SetBorderSize(2); METODO2_8->SetFrameBorderMode(0); METODO2_8->SetFrameBorderMode(0); TH1D *hFitErrRL2__16__8 = new TH1D("hFitErrRL2__16__8","R - errori",40,0.08449133,0.1756762); hFitErrRL2__16__8->SetBinContent(1,4); hFitErrRL2__16__8->SetBinContent(2,3); hFitErrRL2__16__8->SetBinContent(3,9); hFitErrRL2__16__8->SetBinContent(4,14); hFitErrRL2__16__8->SetBinContent(5,22); hFitErrRL2__16__8->SetBinContent(6,38); hFitErrRL2__16__8->SetBinContent(7,43); hFitErrRL2__16__8->SetBinContent(8,55); hFitErrRL2__16__8->SetBinContent(9,83); hFitErrRL2__16__8->SetBinContent(10,65); hFitErrRL2__16__8->SetBinContent(11,75); hFitErrRL2__16__8->SetBinContent(12,66); hFitErrRL2__16__8->SetBinContent(13,76); hFitErrRL2__16__8->SetBinContent(14,56); hFitErrRL2__16__8->SetBinContent(15,73); hFitErrRL2__16__8->SetBinContent(16,47); hFitErrRL2__16__8->SetBinContent(17,49); hFitErrRL2__16__8->SetBinContent(18,41); hFitErrRL2__16__8->SetBinContent(19,30); hFitErrRL2__16__8->SetBinContent(20,28); hFitErrRL2__16__8->SetBinContent(21,17); hFitErrRL2__16__8->SetBinContent(22,24); hFitErrRL2__16__8->SetBinContent(23,13); hFitErrRL2__16__8->SetBinContent(24,8); hFitErrRL2__16__8->SetBinContent(25,7); hFitErrRL2__16__8->SetBinContent(26,7); hFitErrRL2__16__8->SetBinContent(27,4); hFitErrRL2__16__8->SetBinContent(28,5); hFitErrRL2__16__8->SetBinContent(30,1); hFitErrRL2__16__8->SetBinContent(31,3); hFitErrRL2__16__8->SetBinContent(32,1); hFitErrRL2__16__8->SetBinContent(33,1); hFitErrRL2__16__8->SetBinContent(40,1); hFitErrRL2__16__8->SetEntries(969); hFitErrRL2__16__8->SetStats(0); TF1 *gaus8 = new TF1("gaus","gaus",0.08563114,0.1745364); gaus8->SetFillColor(19); gaus8->SetFillStyle(0); gaus8->SetLineColor(2); gaus8->SetLineWidth(2); gaus8->SetChisquare(52.49831); gaus8->SetNDF(30); gaus8->GetXaxis()->SetLabelFont(42); gaus8->GetXaxis()->SetLabelSize(0.035); gaus8->GetXaxis()->SetTitleSize(0.035); gaus8->GetXaxis()->SetTitleFont(42); gaus8->GetYaxis()->SetLabelFont(42); gaus8->GetYaxis()->SetLabelSize(0.035); gaus8->GetYaxis()->SetTitleSize(0.035); gaus8->GetYaxis()->SetTitleFont(42); gaus8->SetParameter(0,71.73788); gaus8->SetParError(0,3.119069); gaus8->SetParLimits(0,0,0); gaus8->SetParameter(1,0.112697); gaus8->SetParError(1,0.0004287075); gaus8->SetParLimits(1,0,0); gaus8->SetParameter(2,0.01171897); gaus8->SetParError(2,0.0003484249); gaus8->SetParLimits(2,0,0.1238761); hFitErrRL2__16__8->GetListOfFunctions()->Add(gaus8); ci = TColor::GetColor("#000099"); hFitErrRL2__16__8->SetLineColor(ci); hFitErrRL2__16__8->GetXaxis()->SetNdivisions(508); hFitErrRL2__16__8->GetXaxis()->SetLabelFont(42); hFitErrRL2__16__8->GetXaxis()->SetLabelOffset(-0.005); hFitErrRL2__16__8->GetXaxis()->SetLabelSize(0.07); hFitErrRL2__16__8->GetXaxis()->SetTitleSize(0.035); hFitErrRL2__16__8->GetXaxis()->SetTitleFont(42); hFitErrRL2__16__8->GetYaxis()->SetNdivisions(508); hFitErrRL2__16__8->GetYaxis()->SetLabelFont(42); hFitErrRL2__16__8->GetYaxis()->SetLabelSize(0.07); hFitErrRL2__16__8->GetYaxis()->SetTitleSize(0.035); hFitErrRL2__16__8->GetYaxis()->SetTitleFont(42); hFitErrRL2__16__8->GetZaxis()->SetLabelFont(42); hFitErrRL2__16__8->GetZaxis()->SetLabelSize(0.035); hFitErrRL2__16__8->GetZaxis()->SetTitleSize(0.035); hFitErrRL2__16__8->GetZaxis()->SetTitleFont(42); hFitErrRL2__16__8->Draw(""); pt = new TPaveText(0.3829375,0.94,0.6170625,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); pt->SetTextSize(0.1009779); AText = pt->AddText("R - errori"); pt->Draw(); METODO2_8->Modified(); METODO2->cd(); METODO2->Modified(); METODO2->cd(); METODO2->SetSelected(METODO2); }
void zj_dphi_8TeV_log() { //=========Macro generated from canvas: default_Canvas/defaultCanvas //========= (Thu Apr 28 10:19:34 2016) by ROOT version6.04/10 TCanvas *default_Canvas = new TCanvas("default_Canvas", "defaultCanvas",0,0,800,800); gStyle->SetOptStat(0); gStyle->SetOptTitle(0); default_Canvas->SetHighLightColor(2); default_Canvas->Range(0,0,1,1); default_Canvas->SetFillColor(0); default_Canvas->SetBorderMode(0); default_Canvas->SetBorderSize(2); default_Canvas->SetTickx(1); default_Canvas->SetTicky(1); default_Canvas->SetLeftMargin(0.14); default_Canvas->SetRightMargin(0.05); default_Canvas->SetTopMargin(0.05); default_Canvas->SetBottomMargin(0.16); default_Canvas->SetFrameLineWidth(2); default_Canvas->SetFrameBorderMode(0); // ------------>Primitives in pad: bottomPad TPad *bottomPad = new TPad("bottomPad", "bottomPad",0.005,0.05,0.995,0.995); bottomPad->Draw(); bottomPad->cd(); bottomPad->Range(0,0,1,1); bottomPad->SetFillColor(0); bottomPad->SetFillStyle(4000); bottomPad->SetBorderMode(0); bottomPad->SetBorderSize(2); bottomPad->SetTickx(1); bottomPad->SetTicky(1); bottomPad->SetLeftMargin(0.14); bottomPad->SetRightMargin(0.05); bottomPad->SetTopMargin(0.05); bottomPad->SetBottomMargin(0.16); bottomPad->SetFrameLineWidth(2); bottomPad->SetFrameBorderMode(0); bottomPad->Modified(); default_Canvas->cd(); // ------------>Primitives in pad: upperPad TPad *upperPad = new TPad("upperPad", "upperPad",0.005,0.05,0.995,0.995); upperPad->Draw(); upperPad->cd(); upperPad->Range(-0.5429913,-2.062865,3.335518,1.327192); upperPad->SetFillColor(0); upperPad->SetFillStyle(4000); upperPad->SetBorderMode(0); upperPad->SetBorderSize(2); upperPad->SetLogy(); upperPad->SetTickx(1); upperPad->SetTicky(1); upperPad->SetLeftMargin(0.14); upperPad->SetRightMargin(0.05); upperPad->SetTopMargin(0.05); upperPad->SetBottomMargin(0.33); upperPad->SetFrameLineWidth(2); upperPad->SetFrameBorderMode(0); upperPad->SetFrameLineWidth(2); upperPad->SetFrameBorderMode(0); TH1F *z_dphi_toterr__37 = new TH1F("z_dphi_toterr__37","z_dphi",6,0,3.141593); z_dphi_toterr__37->SetBinContent(1,0.261202); z_dphi_toterr__37->SetBinContent(2,0.3162337); z_dphi_toterr__37->SetBinContent(3,0.3852335); z_dphi_toterr__37->SetBinContent(4,0.7150939); z_dphi_toterr__37->SetBinContent(5,1.796506); z_dphi_toterr__37->SetBinContent(6,7.258657); z_dphi_toterr__37->SetBinContent(7,3.800624); z_dphi_toterr__37->SetBinError(1,0.03375302); z_dphi_toterr__37->SetBinError(2,0.03634611); z_dphi_toterr__37->SetBinError(3,0.0427511); z_dphi_toterr__37->SetBinError(4,0.05747346); z_dphi_toterr__37->SetBinError(5,0.1278198); z_dphi_toterr__37->SetBinError(6,0.3295685); z_dphi_toterr__37->SetBinError(7,0.1725617); z_dphi_toterr__37->SetEntries(14); z_dphi_toterr__37->SetStats(0); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#ffff00"); z_dphi_toterr__37->SetFillColor(ci); ci = TColor::GetColor("#ffff00"); z_dphi_toterr__37->SetLineColor(ci); z_dphi_toterr__37->SetLineWidth(2); ci = TColor::GetColor("#ffff00"); z_dphi_toterr__37->SetMarkerColor(ci); z_dphi_toterr__37->SetMarkerStyle(0); z_dphi_toterr__37->GetXaxis()->SetNdivisions(4); z_dphi_toterr__37->GetXaxis()->SetLabelFont(132); z_dphi_toterr__37->GetXaxis()->SetLabelOffset(999); z_dphi_toterr__37->GetXaxis()->SetLabelSize(0); z_dphi_toterr__37->GetXaxis()->SetTitleSize(0.06); z_dphi_toterr__37->GetXaxis()->SetTitleFont(132); z_dphi_toterr__37->GetYaxis()->SetTitle("d#sigma(#it{Zj})/d|#Delta#it{#phi} [pb/rad]"); z_dphi_toterr__37->GetYaxis()->SetLabelFont(132); z_dphi_toterr__37->GetYaxis()->SetLabelSize(0.05); z_dphi_toterr__37->GetYaxis()->SetTitleSize(0.06); z_dphi_toterr__37->GetYaxis()->SetTitleOffset(1.3); z_dphi_toterr__37->GetYaxis()->SetTitleFont(132); z_dphi_toterr__37->GetZaxis()->SetLabelFont(132); z_dphi_toterr__37->GetZaxis()->SetLabelSize(0.05); z_dphi_toterr__37->GetZaxis()->SetTitleSize(0.06); z_dphi_toterr__37->GetZaxis()->SetTitleFont(132); z_dphi_toterr__37->Draw("e2"); TH1F *z_dphi_staterr__38 = new TH1F("z_dphi_staterr__38","z_dphi",6,0,3.141593); z_dphi_staterr__38->SetBinContent(1,0.261202); z_dphi_staterr__38->SetBinContent(2,0.3162337); z_dphi_staterr__38->SetBinContent(3,0.3852335); z_dphi_staterr__38->SetBinContent(4,0.7150939); z_dphi_staterr__38->SetBinContent(5,1.796506); z_dphi_staterr__38->SetBinContent(6,7.258657); z_dphi_staterr__38->SetBinContent(7,3.800624); z_dphi_staterr__38->SetBinError(1,0.01764622); z_dphi_staterr__38->SetBinError(2,0.01951211); z_dphi_staterr__38->SetBinError(3,0.02108379); z_dphi_staterr__38->SetBinError(4,0.03021233); z_dphi_staterr__38->SetBinError(5,0.04899558); z_dphi_staterr__38->SetBinError(6,0.1002775); z_dphi_staterr__38->SetBinError(7,0.05250516); z_dphi_staterr__38->SetEntries(14); z_dphi_staterr__38->SetStats(0); ci = TColor::GetColor("#ff9933"); z_dphi_staterr__38->SetFillColor(ci); ci = TColor::GetColor("#ff9933"); z_dphi_staterr__38->SetLineColor(ci); z_dphi_staterr__38->SetLineWidth(2); ci = TColor::GetColor("#ff9933"); z_dphi_staterr__38->SetMarkerColor(ci); z_dphi_staterr__38->SetMarkerStyle(0); z_dphi_staterr__38->GetXaxis()->SetNdivisions(4); z_dphi_staterr__38->GetXaxis()->SetLabelFont(132); z_dphi_staterr__38->GetXaxis()->SetLabelOffset(999); z_dphi_staterr__38->GetXaxis()->SetLabelSize(0); z_dphi_staterr__38->GetXaxis()->SetTitleSize(0.06); z_dphi_staterr__38->GetXaxis()->SetTitleFont(132); z_dphi_staterr__38->GetYaxis()->SetTitle("d#sigma(#it{Zj})/d|#Delta#it{#phi} [pb/rad]"); z_dphi_staterr__38->GetYaxis()->SetLabelFont(132); z_dphi_staterr__38->GetYaxis()->SetLabelSize(0.05); z_dphi_staterr__38->GetYaxis()->SetTitleSize(0.06); z_dphi_staterr__38->GetYaxis()->SetTitleFont(132); z_dphi_staterr__38->GetZaxis()->SetLabelFont(132); z_dphi_staterr__38->GetZaxis()->SetLabelSize(0.05); z_dphi_staterr__38->GetZaxis()->SetTitleSize(0.06); z_dphi_staterr__38->GetZaxis()->SetTitleFont(132); z_dphi_staterr__38->Draw("e2same"); Double_t dphi_toterrs_fx3043[6] = { 0.3403392, 0.863938, 1.387537, 1.911136, 2.434734, 2.958333}; Double_t dphi_toterrs_fy3043[6] = { 0.1926519, 0.2207154, 0.3546338, 0.6864677, 2.01515, 7.779723}; Double_t dphi_toterrs_felx3043[6] = { 0, 0, 0, 0, 0, 0}; Double_t dphi_toterrs_fely3043[6] = { 0.03415733, 0.03577312, 0.05682396, 0.09598937, 0.1897309, 0.5023379}; Double_t dphi_toterrs_fehx3043[6] = { 0, 0, 0, 0, 0, 0}; Double_t dphi_toterrs_fehy3043[6] = { 0.04673612, 0.05211068, 0.07287587, 0.1207667, 0.143423, 0.3949306}; TGraphAsymmErrors *grae = new TGraphAsymmErrors(6,dphi_toterrs_fx3043,dphi_toterrs_fy3043,dphi_toterrs_felx3043,dphi_toterrs_fehx3043,dphi_toterrs_fely3043,dphi_toterrs_fehy3043); grae->SetName("dphi_toterrs"); grae->SetTitle(""); grae->SetFillColor(1); grae->SetLineWidth(2); grae->SetMarkerStyle(24); TH1F *Graph_dphi_toterrs3043 = new TH1F("Graph_dphi_toterrs3043","",100,0.07853982,3.220132); Graph_dphi_toterrs3043->SetMinimum(0.1426451); Graph_dphi_toterrs3043->SetMaximum(8.976269); Graph_dphi_toterrs3043->SetDirectory(0); Graph_dphi_toterrs3043->SetStats(0); Graph_dphi_toterrs3043->SetLineWidth(2); Graph_dphi_toterrs3043->SetMarkerStyle(0); Graph_dphi_toterrs3043->GetXaxis()->SetNdivisions(4); Graph_dphi_toterrs3043->GetXaxis()->SetLabelFont(132); Graph_dphi_toterrs3043->GetXaxis()->SetLabelOffset(999); Graph_dphi_toterrs3043->GetXaxis()->SetLabelSize(0); Graph_dphi_toterrs3043->GetXaxis()->SetTitleSize(0.06); Graph_dphi_toterrs3043->GetXaxis()->SetTitleFont(132); Graph_dphi_toterrs3043->GetYaxis()->SetTitle("d#sigma(#it{Zj})/d|#Delta#it{#phi} [pb/rad]"); Graph_dphi_toterrs3043->GetYaxis()->SetLabelFont(132); Graph_dphi_toterrs3043->GetYaxis()->SetLabelSize(0.05); Graph_dphi_toterrs3043->GetYaxis()->SetTitleSize(0.06); Graph_dphi_toterrs3043->GetYaxis()->SetTitleFont(132); Graph_dphi_toterrs3043->GetZaxis()->SetLabelFont(132); Graph_dphi_toterrs3043->GetZaxis()->SetLabelSize(0.05); Graph_dphi_toterrs3043->GetZaxis()->SetTitleSize(0.06); Graph_dphi_toterrs3043->GetZaxis()->SetTitleFont(132); grae->SetHistogram(Graph_dphi_toterrs3043); grae->Draw("p1p"); Double_t _fx3044[6] = { 0.3403392, 0.863938, 1.387537, 1.911136, 2.434734, 2.958333}; Double_t _fy3044[6] = { 0.1926519, 0.2207154, 0.3546338, 0.6864677, 2.01515, 7.779723}; Double_t _felx3044[6] = { 0, 0, 0, 0, 0, 0}; Double_t _fely3044[6] = { 0.02873042, 0.03223617, 0.04948444, 0.07740101, 0.1117696, 0.3251484}; Double_t _fehx3044[6] = { 0, 0, 0, 0, 0, 0}; Double_t _fehy3044[6] = { 0.03948655, 0.04420709, 0.06698785, 0.1028379, 0.1104173, 0.2636435}; grae = new TGraphAsymmErrors(6,_fx3044,_fy3044,_felx3044,_fehx3044,_fely3044,_fehy3044); grae->SetName(""); grae->SetTitle(""); grae->SetFillColor(1); grae->SetLineWidth(2); grae->SetMarkerStyle(24); TH1F *Graph_Graph3044 = new TH1F("Graph_Graph3044","",100,0.07853982,3.220132); Graph_Graph3044->SetMinimum(0.1475293); Graph_Graph3044->SetMaximum(8.831311); Graph_Graph3044->SetDirectory(0); Graph_Graph3044->SetStats(0); Graph_Graph3044->SetLineWidth(2); Graph_Graph3044->SetMarkerStyle(0); Graph_Graph3044->GetXaxis()->SetNdivisions(4); Graph_Graph3044->GetXaxis()->SetLabelFont(132); Graph_Graph3044->GetXaxis()->SetLabelOffset(999); Graph_Graph3044->GetXaxis()->SetLabelSize(0); Graph_Graph3044->GetXaxis()->SetTitleSize(0.06); Graph_Graph3044->GetXaxis()->SetTitleFont(132); Graph_Graph3044->GetYaxis()->SetTitle("d#sigma(#it{Zj})/d|#Delta#it{#phi} [pb/rad]"); Graph_Graph3044->GetYaxis()->SetLabelFont(132); Graph_Graph3044->GetYaxis()->SetLabelSize(0.05); Graph_Graph3044->GetYaxis()->SetTitleSize(0.06); Graph_Graph3044->GetYaxis()->SetTitleFont(132); Graph_Graph3044->GetZaxis()->SetLabelFont(132); Graph_Graph3044->GetZaxis()->SetLabelSize(0.05); Graph_Graph3044->GetZaxis()->SetTitleSize(0.06); Graph_Graph3044->GetZaxis()->SetTitleFont(132); grae->SetHistogram(Graph_Graph3044); grae->Draw("p1p"); Double_t dphi_toterrs_fx3045[6] = { 0.1832596, 0.7068583, 1.230457, 1.754056, 2.277655, 2.801253}; Double_t dphi_toterrs_fy3045[6] = { 0.3071206, 0.3788296, 0.5235754, 0.9026085, 2.09773, 8.042891}; Double_t dphi_toterrs_felx3045[6] = { 0, 0, 0, 0, 0, 0}; Double_t dphi_toterrs_fely3045[6] = { 0.03223837, 0.05049376, 0.0513308, 0.07859791, 0.1671821, 0.6048482}; Double_t dphi_toterrs_fehx3045[6] = { 0, 0, 0, 0, 0, 0}; Double_t dphi_toterrs_fehy3045[6] = { 0.05069997, 0.04670219, 0.05741781, 0.0972528, 0.2140117, 0.6377428}; grae = new TGraphAsymmErrors(6,dphi_toterrs_fx3045,dphi_toterrs_fy3045,dphi_toterrs_felx3045,dphi_toterrs_fehx3045,dphi_toterrs_fely3045,dphi_toterrs_fehy3045); grae->SetName("dphi_toterrs"); grae->SetTitle(""); grae->SetFillColor(1); grae->SetLineWidth(2); grae->SetMarkerStyle(20); TH1F *Graph_dphi_toterrs3045 = new TH1F("Graph_dphi_toterrs3045","",100,0,3.063053); Graph_dphi_toterrs3045->SetMinimum(0.247394); Graph_dphi_toterrs3045->SetMaximum(9.521209); Graph_dphi_toterrs3045->SetDirectory(0); Graph_dphi_toterrs3045->SetStats(0); Graph_dphi_toterrs3045->SetLineWidth(2); Graph_dphi_toterrs3045->SetMarkerStyle(0); Graph_dphi_toterrs3045->GetXaxis()->SetNdivisions(4); Graph_dphi_toterrs3045->GetXaxis()->SetLabelFont(132); Graph_dphi_toterrs3045->GetXaxis()->SetLabelOffset(999); Graph_dphi_toterrs3045->GetXaxis()->SetLabelSize(0); Graph_dphi_toterrs3045->GetXaxis()->SetTitleSize(0.06); Graph_dphi_toterrs3045->GetXaxis()->SetTitleFont(132); Graph_dphi_toterrs3045->GetYaxis()->SetTitle("d#sigma(#it{Zj})/d|#Delta#it{#phi} [pb/rad]"); Graph_dphi_toterrs3045->GetYaxis()->SetLabelFont(132); Graph_dphi_toterrs3045->GetYaxis()->SetLabelSize(0.05); Graph_dphi_toterrs3045->GetYaxis()->SetTitleSize(0.06); Graph_dphi_toterrs3045->GetYaxis()->SetTitleFont(132); Graph_dphi_toterrs3045->GetZaxis()->SetLabelFont(132); Graph_dphi_toterrs3045->GetZaxis()->SetLabelSize(0.05); Graph_dphi_toterrs3045->GetZaxis()->SetTitleSize(0.06); Graph_dphi_toterrs3045->GetZaxis()->SetTitleFont(132); grae->SetHistogram(Graph_dphi_toterrs3045); grae->Draw("p1p"); Double_t _fx3046[6] = { 0.1832596, 0.7068583, 1.230457, 1.754056, 2.277655, 2.801253}; Double_t _fy3046[6] = { 0.3071206, 0.3788296, 0.5235754, 0.9026085, 2.09773, 8.042891}; Double_t _felx3046[6] = { 0, 0, 0, 0, 0, 0}; Double_t _fely3046[6] = { 0.02710968, 0.03295216, 0.04124188, 0.06402796, 0.1338949, 0.4694553}; Double_t _fehx3046[6] = { 0, 0, 0, 0, 0, 0}; Double_t _fehy3046[6] = { 0.03469016, 0.04020747, 0.048986, 0.07362466, 0.1488417, 0.5027875}; grae = new TGraphAsymmErrors(6,_fx3046,_fy3046,_felx3046,_fehx3046,_fely3046,_fehy3046); grae->SetName(""); grae->SetTitle(""); grae->SetFillColor(1); grae->SetLineWidth(2); grae->SetMarkerStyle(20); TH1F *Graph_Graph3046 = new TH1F("Graph_Graph3046","",100,0,3.063053); Graph_Graph3046->SetMinimum(0.2520099); Graph_Graph3046->SetMaximum(9.372245); Graph_Graph3046->SetDirectory(0); Graph_Graph3046->SetStats(0); Graph_Graph3046->SetLineWidth(2); Graph_Graph3046->SetMarkerStyle(0); Graph_Graph3046->GetXaxis()->SetNdivisions(4); Graph_Graph3046->GetXaxis()->SetLabelFont(132); Graph_Graph3046->GetXaxis()->SetLabelOffset(999); Graph_Graph3046->GetXaxis()->SetLabelSize(0); Graph_Graph3046->GetXaxis()->SetTitleSize(0.06); Graph_Graph3046->GetXaxis()->SetTitleFont(132); Graph_Graph3046->GetYaxis()->SetTitle("d#sigma(#it{Zj})/d|#Delta#it{#phi} [pb/rad]"); Graph_Graph3046->GetYaxis()->SetLabelFont(132); Graph_Graph3046->GetYaxis()->SetLabelSize(0.05); Graph_Graph3046->GetYaxis()->SetTitleSize(0.06); Graph_Graph3046->GetYaxis()->SetTitleFont(132); Graph_Graph3046->GetZaxis()->SetLabelFont(132); Graph_Graph3046->GetZaxis()->SetLabelSize(0.05); Graph_Graph3046->GetZaxis()->SetTitleSize(0.06); Graph_Graph3046->GetZaxis()->SetTitleFont(132); grae->SetHistogram(Graph_Graph3046); grae->Draw("p1p"); TLegend *leg = new TLegend(0.2,0.57,0.5,0.82,NULL,"brNDC"); leg->SetBorderSize(0); leg->SetTextFont(132); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(2); leg->SetFillColor(10); leg->SetFillStyle(0); TLegendEntry *entry=leg->AddEntry("data_stat","Data_{stat}","f"); ci = TColor::GetColor("#ff9933"); entry->SetFillColor(ci); entry->SetFillStyle(1001); entry->SetLineStyle(1); entry->SetLineWidth(2); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(132); entry=leg->AddEntry("data_tot","Data_{tot}","f"); ci = TColor::GetColor("#ffff00"); entry->SetFillColor(ci); entry->SetFillStyle(1001); entry->SetLineStyle(1); entry->SetLineWidth(2); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(132); entry=leg->AddEntry("powheg_temp","POWHEG","p"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(20); entry->SetMarkerSize(1); entry->SetTextFont(132); entry=leg->AddEntry("amcatnlo_temp","aMC@NLO","p"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(24); entry->SetMarkerSize(1); entry->SetTextFont(132); leg->Draw(); TPaveText *pt = new TPaveText(0.2,0.8,0.55,0.95,"brNDC"); pt->SetBorderSize(0); pt->SetFillStyle(0); pt->SetLineWidth(2); pt->SetTextFont(132); TText *AText = pt->AddText("LHCb, #sqrt{s} = 8 TeV"); pt->Draw(); TH1F *z_dphi_toterr_copy__39 = new TH1F("z_dphi_toterr_copy__39","z_dphi",6,0,3.141593); z_dphi_toterr_copy__39->SetBinContent(1,0.261202); z_dphi_toterr_copy__39->SetBinContent(2,0.3162337); z_dphi_toterr_copy__39->SetBinContent(3,0.3852335); z_dphi_toterr_copy__39->SetBinContent(4,0.7150939); z_dphi_toterr_copy__39->SetBinContent(5,1.796506); z_dphi_toterr_copy__39->SetBinContent(6,7.258657); z_dphi_toterr_copy__39->SetBinContent(7,3.800624); z_dphi_toterr_copy__39->SetBinError(1,0.03375302); z_dphi_toterr_copy__39->SetBinError(2,0.03634611); z_dphi_toterr_copy__39->SetBinError(3,0.0427511); z_dphi_toterr_copy__39->SetBinError(4,0.05747346); z_dphi_toterr_copy__39->SetBinError(5,0.1278198); z_dphi_toterr_copy__39->SetBinError(6,0.3295685); z_dphi_toterr_copy__39->SetBinError(7,0.1725617); z_dphi_toterr_copy__39->SetEntries(14); z_dphi_toterr_copy__39->SetDirectory(0); z_dphi_toterr_copy__39->SetStats(0); ci = TColor::GetColor("#ffff00"); z_dphi_toterr_copy__39->SetFillColor(ci); ci = TColor::GetColor("#ffff00"); z_dphi_toterr_copy__39->SetLineColor(ci); z_dphi_toterr_copy__39->SetLineWidth(2); ci = TColor::GetColor("#ffff00"); z_dphi_toterr_copy__39->SetMarkerColor(ci); z_dphi_toterr_copy__39->SetMarkerStyle(0); z_dphi_toterr_copy__39->GetXaxis()->SetNdivisions(4); z_dphi_toterr_copy__39->GetXaxis()->SetLabelFont(132); z_dphi_toterr_copy__39->GetXaxis()->SetLabelOffset(999); z_dphi_toterr_copy__39->GetXaxis()->SetLabelSize(0); z_dphi_toterr_copy__39->GetXaxis()->SetTitleSize(0.06); z_dphi_toterr_copy__39->GetXaxis()->SetTitleFont(132); z_dphi_toterr_copy__39->GetYaxis()->SetTitle("d#sigma(#it{Zj})/d|#Delta#it{#phi} [pb/rad]"); z_dphi_toterr_copy__39->GetYaxis()->SetLabelFont(132); z_dphi_toterr_copy__39->GetYaxis()->SetLabelSize(0.05); z_dphi_toterr_copy__39->GetYaxis()->SetTitleSize(0.06); z_dphi_toterr_copy__39->GetYaxis()->SetTitleOffset(1.3); z_dphi_toterr_copy__39->GetYaxis()->SetTitleFont(132); z_dphi_toterr_copy__39->GetZaxis()->SetLabelFont(132); z_dphi_toterr_copy__39->GetZaxis()->SetLabelSize(0.05); z_dphi_toterr_copy__39->GetZaxis()->SetTitleSize(0.06); z_dphi_toterr_copy__39->GetZaxis()->SetTitleFont(132); z_dphi_toterr_copy__39->Draw("sameaxis"); upperPad->Modified(); default_Canvas->cd(); // ------------>Primitives in pad: lowerPad TPad *lowerPad = new TPad("lowerPad", "lowerPad",0.005,0.05,0.995,0.995); lowerPad->Draw(); lowerPad->cd(); lowerPad->Range(-0.5429913,-0.4371795,3.335518,5.614103); lowerPad->SetFillColor(0); lowerPad->SetFillStyle(4000); lowerPad->SetBorderMode(0); lowerPad->SetBorderSize(2); lowerPad->SetTickx(1); lowerPad->SetTicky(1); lowerPad->SetLeftMargin(0.14); lowerPad->SetRightMargin(0.05); lowerPad->SetTopMargin(0.665); lowerPad->SetBottomMargin(0.14); lowerPad->SetFrameLineWidth(2); lowerPad->SetFrameBorderMode(0); lowerPad->SetFrameLineWidth(2); lowerPad->SetFrameBorderMode(0); TH1F *zj_dphi_8TeV_log_400_1001_0ratiocomp0__40 = new TH1F("zj_dphi_8TeV_log_400_1001_0ratiocomp0__40","z_dphi",6,0,3.141593); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinContent(1,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinContent(2,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinContent(3,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinContent(4,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinContent(5,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinContent(6,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinContent(7,3.800624); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinError(1,0.1292219); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinError(2,0.1149343); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinError(3,0.1109745); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinError(4,0.08037191); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinError(5,0.07114914); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinError(6,0.04540351); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetBinError(7,0.1725617); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetMinimum(0.41); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetMaximum(1.59); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetEntries(20); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetStats(0); ci = TColor::GetColor("#ffff00"); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetFillColor(ci); ci = TColor::GetColor("#ffff00"); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetLineColor(ci); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetLineWidth(2); ci = TColor::GetColor("#ffff00"); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetMarkerColor(ci); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->SetMarkerStyle(0); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetXaxis()->SetTitle("|#Delta#it{#phi}| [rad]"); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetXaxis()->SetNdivisions(4); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetXaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetXaxis()->SetLabelOffset(0.02); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetXaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetXaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetXaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->SetTitle("Ratio"); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->CenterTitle(true); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->SetNdivisions(505); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->SetTickLength(0.12325); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->SetTitleOffset(1.3); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetYaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetZaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetZaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetZaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->GetZaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0__40->Draw("e2"); TH1F *zj_dphi_8TeV_log_400_1001_0ratiocomp1__41 = new TH1F("zj_dphi_8TeV_log_400_1001_0ratiocomp1__41","z_dphi",6,0,3.141593); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinContent(1,1); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinContent(2,1); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinContent(3,1); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinContent(4,1); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinContent(5,1); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinContent(6,1); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinContent(7,3.800624); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinError(1,0.06755777); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinError(2,0.06170157); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinError(3,0.0547299); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinError(4,0.04224946); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinError(5,0.02727271); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinError(6,0.01381488); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetBinError(7,0.05250516); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetMinimum(0.41); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetMaximum(1.59); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetEntries(20); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetStats(0); ci = TColor::GetColor("#ff9933"); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetFillColor(ci); ci = TColor::GetColor("#ff9933"); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetLineColor(ci); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetLineWidth(2); ci = TColor::GetColor("#ff9933"); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetMarkerColor(ci); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->SetMarkerStyle(0); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetXaxis()->SetTitle("|#Delta#it{#phi}| [rad]"); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetXaxis()->SetNdivisions(4); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetXaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetXaxis()->SetLabelOffset(0.02); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetXaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetXaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetXaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetYaxis()->SetTitle("Ratio"); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetYaxis()->CenterTitle(true); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetYaxis()->SetNdivisions(505); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetYaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetYaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetYaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetYaxis()->SetTickLength(0.12325); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetYaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetZaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetZaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetZaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->GetZaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp1__41->Draw("e2same"); Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp2_fx3047[6] = { 0.3403392, 0.863938, 1.387537, 1.911136, 2.434734, 2.958333}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp2_fy3047[6] = { 0.7375589, 0.6979502, 0.9205685, 0.9599686, 1.121705, 1.071786}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp2_felx3047[6] = { 0, 0, 0, 0, 0, 0}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp2_fely3047[6] = { 0.1307698, 0.1131224, 0.1475052, 0.1342332, 0.1056111, 0.06920535}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp2_fehx3047[6] = { 0, 0, 0, 0, 0, 0}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp2_fehy3047[6] = { 0.1789271, 0.1647854, 0.1891732, 0.1688822, 0.07983441, 0.05440822}; grae = new TGraphAsymmErrors(6,zj_dphi_8TeV_log_400_1001_0ratiocomp2_fx3047,zj_dphi_8TeV_log_400_1001_0ratiocomp2_fy3047,zj_dphi_8TeV_log_400_1001_0ratiocomp2_felx3047,zj_dphi_8TeV_log_400_1001_0ratiocomp2_fehx3047,zj_dphi_8TeV_log_400_1001_0ratiocomp2_fely3047,zj_dphi_8TeV_log_400_1001_0ratiocomp2_fehy3047); grae->SetName("zj_dphi_8TeV_log_400_1001_0ratiocomp2"); grae->SetTitle(""); grae->SetFillColor(1); grae->SetLineWidth(2); grae->SetMarkerStyle(24); TH1F *Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047 = new TH1F("Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047","",100,0.07853982,3.220132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->SetMinimum(0.41); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->SetMaximum(1.59); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->SetDirectory(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->SetStats(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->SetLineWidth(2); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->SetMarkerStyle(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetXaxis()->SetTitle("|#Delta#it{#phi}| [rad]"); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetXaxis()->SetNdivisions(4); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetXaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetXaxis()->SetLabelOffset(0.02); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetXaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetXaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetXaxis()->SetTitleFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetYaxis()->SetTitle("Ratio"); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetYaxis()->CenterTitle(true); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetYaxis()->SetNdivisions(505); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetYaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetYaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetYaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetYaxis()->SetTitleFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetZaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetZaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetZaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047->GetZaxis()->SetTitleFont(132); grae->SetHistogram(Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp23047); grae->Draw("p1"); Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp3_fx3048[6] = { 0.3403392, 0.863938, 1.387537, 1.911136, 2.434734, 2.958333}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp3_fy3048[6] = { 0.7375589, 0.6979502, 0.9205685, 0.9599686, 1.121705, 1.071786}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp3_felx3048[6] = { 0, 0, 0, 0, 0, 0}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp3_fely3048[6] = { 0.1099931, 0.1019378, 0.1284531, 0.1082389, 0.06221498, 0.04479457}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp3_fehx3048[6] = { 0, 0, 0, 0, 0, 0}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp3_fehy3048[6] = { 0.1511724, 0.1397925, 0.1738889, 0.1438103, 0.06146226, 0.03632125}; grae = new TGraphAsymmErrors(6,zj_dphi_8TeV_log_400_1001_0ratiocomp3_fx3048,zj_dphi_8TeV_log_400_1001_0ratiocomp3_fy3048,zj_dphi_8TeV_log_400_1001_0ratiocomp3_felx3048,zj_dphi_8TeV_log_400_1001_0ratiocomp3_fehx3048,zj_dphi_8TeV_log_400_1001_0ratiocomp3_fely3048,zj_dphi_8TeV_log_400_1001_0ratiocomp3_fehy3048); grae->SetName("zj_dphi_8TeV_log_400_1001_0ratiocomp3"); grae->SetTitle(""); grae->SetFillColor(1); grae->SetLineWidth(2); grae->SetMarkerStyle(24); TH1F *Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048 = new TH1F("Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048","",100,0.07853982,3.220132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->SetMinimum(0.41); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->SetMaximum(1.59); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->SetDirectory(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->SetStats(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->SetLineWidth(2); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->SetMarkerStyle(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetXaxis()->SetTitle("|#Delta#it{#phi}| [rad]"); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetXaxis()->SetNdivisions(4); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetXaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetXaxis()->SetLabelOffset(0.02); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetXaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetXaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetXaxis()->SetTitleFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetYaxis()->SetTitle("Ratio"); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetYaxis()->CenterTitle(true); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetYaxis()->SetNdivisions(505); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetYaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetYaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetYaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetYaxis()->SetTitleFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetZaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetZaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetZaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048->GetZaxis()->SetTitleFont(132); grae->SetHistogram(Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp33048); grae->Draw("p1"); Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp4_fx3049[6] = { 0.1832596, 0.7068583, 1.230457, 1.754056, 2.277655, 2.801253}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp4_fy3049[6] = { 1.175797, 1.197942, 1.359112, 1.262224, 1.167673, 1.108041}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp4_felx3049[6] = { 0, 0, 0, 0, 0, 0}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp4_fely3049[6] = { 0.1234231, 0.1596723, 0.1332459, 0.1099127, 0.09305962, 0.08332785}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp4_fehx3049[6] = { 0, 0, 0, 0, 0, 0}; Double_t zj_dphi_8TeV_log_400_1001_0ratiocomp4_fehy3049[6] = { 0.1941025, 0.1476825, 0.1490468, 0.136, 0.1191266, 0.08785962}; grae = new TGraphAsymmErrors(6,zj_dphi_8TeV_log_400_1001_0ratiocomp4_fx3049,zj_dphi_8TeV_log_400_1001_0ratiocomp4_fy3049,zj_dphi_8TeV_log_400_1001_0ratiocomp4_felx3049,zj_dphi_8TeV_log_400_1001_0ratiocomp4_fehx3049,zj_dphi_8TeV_log_400_1001_0ratiocomp4_fely3049,zj_dphi_8TeV_log_400_1001_0ratiocomp4_fehy3049); grae->SetName("zj_dphi_8TeV_log_400_1001_0ratiocomp4"); grae->SetTitle(""); grae->SetFillColor(1); grae->SetLineWidth(2); grae->SetMarkerStyle(20); TH1F *Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049 = new TH1F("Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049","",100,0,3.063053); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->SetMinimum(0.41); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->SetMaximum(1.59); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->SetDirectory(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->SetStats(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->SetLineWidth(2); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->SetMarkerStyle(0); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetXaxis()->SetTitle("|#Delta#it{#phi}| [rad]"); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetXaxis()->SetNdivisions(4); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetXaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetXaxis()->SetLabelOffset(0.02); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetXaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetXaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetXaxis()->SetTitleFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetYaxis()->SetTitle("Ratio"); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetYaxis()->CenterTitle(true); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetYaxis()->SetNdivisions(505); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetYaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetYaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetYaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetYaxis()->SetTitleFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetZaxis()->SetLabelFont(132); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetZaxis()->SetLabelSize(0.05); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetZaxis()->SetTitleSize(0.06); Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049->GetZaxis()->SetTitleFont(132); grae->SetHistogram(Graph_zj_dphi_8TeV_log_400_1001_0ratiocomp43049); grae->Draw("p1"); TH1F *zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42 = new TH1F("zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42","z_dphi",6,0,3.141593); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinContent(1,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinContent(2,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinContent(3,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinContent(4,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinContent(5,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinContent(6,1); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinContent(7,3.800624); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinError(1,0.1292219); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinError(2,0.1149343); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinError(3,0.1109745); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinError(4,0.08037191); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinError(5,0.07114914); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinError(6,0.04540351); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetBinError(7,0.1725617); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetMinimum(0.41); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetMaximum(1.59); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetEntries(20); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetDirectory(0); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetStats(0); ci = TColor::GetColor("#ffff00"); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetFillColor(ci); ci = TColor::GetColor("#ffff00"); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetLineColor(ci); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetLineWidth(2); ci = TColor::GetColor("#ffff00"); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetMarkerColor(ci); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->SetMarkerStyle(0); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetXaxis()->SetTitle("|#Delta#it{#phi}| [rad]"); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetXaxis()->SetNdivisions(4); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetXaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetXaxis()->SetLabelOffset(0.02); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetXaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetXaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetXaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->SetTitle("Ratio"); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->CenterTitle(true); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->SetNdivisions(505); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->SetTickLength(0.12325); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->SetTitleOffset(1.3); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetYaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetZaxis()->SetLabelFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetZaxis()->SetLabelSize(0.05); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetZaxis()->SetTitleSize(0.06); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->GetZaxis()->SetTitleFont(132); zj_dphi_8TeV_log_400_1001_0ratiocomp0_copy__42->Draw("sameaxis"); lowerPad->Modified(); default_Canvas->cd(); default_Canvas->Modified(); default_Canvas->cd(); default_Canvas->SetSelected(default_Canvas); }
void Rapid2DLL::Plot_Contours( TString controlled_parameter1, TString controlled_parameter2, TH1* nll_hist, vector<pair<TMultiGraph*,TString> > nll_contours, TString filename, TRandom* rand, vector<string> other_params ) { if( rand == NULL ) rand = gRandom; //TPaveText* label = NULL; string addLHCb="--isFinal"; string addSMPhisString="--addPhis"; bool addSMPhis = StringOperations::VectorContains( &other_params, &addSMPhisString ) != -1; /* if( StringOperations::VectorContains( &other_params, &addLHCb ) != -1 ) label = Histogram_Processing::addLHCbLabel( "", true ); else label = Histogram_Processing::addLHCbLabel( "", false ); */ TPaveText* label = EdStyle::LHCbLabel(); if( StringOperations::VectorContains( &other_params, &addLHCb ) == -1 ) { label->AddText( "" ); label->AddText( "Preliminary" ); } //TLegend* leg = EdStyle::LHCbLegend();//0.65, 0.65, 0.9, 0.9 ); TLegend* leg = new TLegend( 0.675, 0.725, 0.9, 0.925 ); leg->SetFillColor( kWhite ); leg->SetFillStyle( EdStyle::GetTransparentFillStyle() ); leg->SetTextSize( 0.050 );//EdStyle::GetLHCbTextSize() ); leg->SetTextFont( EdStyle::GetLHCbFont() ); //TString TCanvas_Namea("TCanvas_");TCanvas_Namea+=rand->Rndm(); //TCanvas* c1a = EdStyle::RapidFitCanvas( TCanvas_Namea, TCanvas_Namea ); //nll_hist->Draw("AXIS"); //c1a->Update(); TString TCanvas_Name("TCanvas_"); TCanvas_Name+=rand->Rndm(); TCanvas_Name = StringOperations::Clean( TCanvas_Name ); TCanvas* c1 = EdStyle::RapidFitCanvas( TCanvas_Name, TCanvas_Name ); nll_hist->Draw("AXIS"); //nll_contours.back().first->Draw("AXIS"); //c1->Update(); //nll_contours.back().first->GetXaxis()->SetRangeUser( nll_hist->GetXaxis()->GetXmin(), nll_hist->GetXaxis()->GetXmax() ); //nll_contours.back().first->GetYaxis()->SetRangeUser( nll_hist->GetYaxis()->GetXmin(), nll_hist->GetYaxis()->GetXmax() ); c1->Update(); unsigned int cont_num=0; for( vector<pair<TMultiGraph*,TString> >::iterator cont_i = nll_contours.begin(); cont_i != nll_contours.end(); ++cont_i, ++cont_num ) { cont_i->first->Draw("C"); TList* this_cont = cont_i->first->GetListOfGraphs(); for( unsigned int i=0; i< (unsigned)this_cont->GetSize(); ++i ) { TGraph* this_part = (TGraph*) this_cont->At( i ); this_part->SetLineColor( (Color_t)Rapid2DLL::GetColors( cont_num ) ); this_part->SetLineStyle( (Style_t)Rapid2DLL::GetStyle( cont_num ) ); this_part->SetLineWidth( (Width_t)Rapid2DLL::GetFunctionLineWidth() ); } leg->AddEntry( cont_i->first->GetListOfGraphs()->First() , nll_contours[cont_num].second, "L" ); } nll_hist->GetXaxis()->SetTitle( EdStyle::GetParamRootName(controlled_parameter1) + " " + EdStyle::GetParamRootUnit(controlled_parameter1) ); nll_hist->GetYaxis()->SetTitle( EdStyle::GetParamRootName(controlled_parameter2) + " " + EdStyle::GetParamRootUnit(controlled_parameter2) ); c1->Update(); leg->Draw(); if( label ) label->Draw(); if( addSMPhis ) { double* px=NULL; double* xerr=NULL; double* py=NULL; double* yerr=NULL; if( controlled_parameter1 == "Phi_s" ) { px = new double[1]; px[0] = -0.036;//0.087; xerr = new double[1]; xerr[0] = 0.002;//0.021; py = new double[1]; py[0] = 0.087;//0.036; yerr = new double[1]; yerr[0] = 0.021;//0.002; } else { px = new double[1]; px[0] = 0.087; xerr = new double[1]; xerr[0] = 0.021; py = new double[1]; py[0] = -0.036; yerr = new double[1]; yerr[0] = 0.002; } if( ( controlled_parameter1 == "Phi_s" || controlled_parameter1 == "deltaGamma" )&&( controlled_parameter2 == "Phi_s" || controlled_parameter2 == "deltaGamma" ) ) { TGraphErrors* CV = new TGraphErrors( 1, px, py, xerr, yerr ); CV->SetName( "Standard Model" ); leg->AddEntry( CV, "Standard Model", "PE" ); CV->Draw("LP SAME"); } } c1->Update(); Histogram_Processing::Silent_Print( c1, filename ); return; }
void PlotField2D( const TString &sim, Int_t time, Int_t index = 0, Float_t zoom=2, Int_t Nbins=2, const TString &options="") { #ifdef __CINT__ gSystem->Load("libptools.so"); #endif // Load PData PData *pData = PData::Get(sim.Data()); pData->LoadFileNames(time); if(!pData->IsInit()) return; // Refresh and Style PGlobals::Initialize(); // Coloured palettes gROOT->Macro("PPalettes.C"); TString opt = options; // More makeup if(opt.Contains("grid")) { gStyle->SetPadGridX(1); gStyle->SetPadGridY(1); } gStyle->SetTitleFont(42); gStyle->SetStatFont(42); gStyle->SetTextFont(42); gStyle->SetTitleFont(42,"xyz"); gStyle->SetLabelFont(42,"xyz"); // Some plasma constants Double_t n0 = pData->GetPlasmaDensity(); Double_t kp = pData->GetPlasmaK(); Double_t skindepth = 1.; if(kp!=0.0) skindepth = 1/kp; Double_t E0 = pData->GetPlasmaE0(); // Some beam properties: Float_t Ebeam = pData->GetBeamEnergy() * PUnits::MeV; Float_t gamma = Ebeam / PConst::ElectronMassE; Float_t vbeam = TMath::Sqrt(1 - 1/(gamma*gamma)); // cout << Form(" - Bunch gamma = %8.4f", gamma ) << endl; // cout << Form(" - Bunch velocity = %8.4f c", vbeam ) << endl; Float_t nb = pData->GetBeamDensity(); // Time in OU Float_t Time = pData->GetRealTime(); // z start of the plasma in normalized units. Float_t zStartPlasma = pData->GetPlasmaStart()*kp; // z start of the beam in normalized units. Float_t zStartBeam = pData->GetBeamStart()*kp; // z start of the neutral in normalized units. Float_t zStartNeutral = pData->GetNeutralStart()*kp; // z end of the neutral in normalized units. Float_t zEndNeutral = pData->GetNeutralEnd()*kp; if(opt.Contains("center")) { Time -= zStartPlasma; if(opt.Contains("comov")) // Centers on the head of the beam. Time += zStartBeam; } Float_t shiftz = pData->Shift(opt); // cout << "Shift = " << shiftz << endl; // Calculate the "axis range" in number of bins. If Nbins==0 a RMS width is taken. Double_t rms0 = pData->GetBeamRmsY() * kp; if(pData->IsCyl()) rms0 = pData->GetBeamRmsR() * kp; Int_t FirstyBin = 0; Int_t LastyBin = 0; if(Nbins==0) { Nbins = TMath::Nint(rms0 / pData->GetDX(1)); } // Slice width limits. if(!pData->IsCyl()) { FirstyBin = pData->GetNX(1)/2 + 1 - Nbins; LastyBin = pData->GetNX(1)/2 + Nbins; } else { FirstyBin = 1; LastyBin = Nbins; } // ------------------------------------------------------------------------------- // Get field histos const Int_t Nfields = 3; TH2F **hE2D = new TH2F*[Nfields]; for(Int_t i=0;i<Nfields;i++) { hE2D[i] = NULL; if(i!=index) continue; if(!pData->GetEfieldFileName(i)) continue; char hName[24]; sprintf(hName,"hE2D_%i",i); hE2D[i] = (TH2F*) gROOT->FindObject(hName); if(hE2D[i]) delete hE2D[i]; if(!pData->Is3D()) hE2D[i] = pData->GetEField(i,opt); else hE2D[i] = pData->GetEField2DSliceZY(i,-1,Nbins,opt+"avg"); hE2D[i]->SetName(hName); hE2D[i]->GetXaxis()->CenterTitle(); hE2D[i]->GetYaxis()->CenterTitle(); hE2D[i]->GetZaxis()->CenterTitle(); if(opt.Contains("comov")) hE2D[i]->GetXaxis()->SetTitle("k_{p} #zeta"); else hE2D[i]->GetXaxis()->SetTitle("k_{p} z"); if(pData->IsCyl()) hE2D[i]->GetYaxis()->SetTitle("k_{p} r"); else hE2D[i]->GetYaxis()->SetTitle("k_{p} x"); if(i==0) hE2D[i]->GetZaxis()->SetTitle("E_{z} / E_{0}"); else if(i==1) hE2D[i]->GetZaxis()->SetTitle("E_{y} / E_{0}"); else if(i==2) hE2D[i]->GetZaxis()->SetTitle("E_{x} / E_{0}"); } // Tunning the Histograms // --------------------- // Chaning to user units: // -------------------------- if(opt.Contains("units") && n0) { for(Int_t i=0;i<Nfields;i++) { if(i!=index) continue; Int_t NbinsX = hE2D[i]->GetNbinsX(); Float_t xMin = skindepth * hE2D[i]->GetXaxis()->GetXmin() / PUnits::um; Float_t xMax = skindepth * hE2D[i]->GetXaxis()->GetXmax() / PUnits::um; Int_t NbinsY = hE2D[i]->GetNbinsY(); Float_t yMin = skindepth * hE2D[i]->GetYaxis()->GetXmin() / PUnits::um; Float_t yMax = skindepth * hE2D[i]->GetYaxis()->GetXmax() / PUnits::um; hE2D[i]->SetBins(NbinsX,xMin,xMax,NbinsY,yMin,yMax); for(Int_t j=0;j<hE2D[i]->GetNbinsX();j++) { for(Int_t k=0;k<hE2D[i]->GetNbinsY();k++) { hE2D[i]->SetBinContent(j,k, hE2D[i]->GetBinContent(j,k) * ( E0 / (PUnits::GV/PUnits::m) ) ); } } if(pData->IsCyl()) hE2D[i]->GetYaxis()->SetTitle("r [#mum]"); else hE2D[i]->GetYaxis()->SetTitle("x [#mum]"); if(opt.Contains("comov")) hE2D[i]->GetXaxis()->SetTitle("#zeta [#mum]"); else hE2D[i]->GetXaxis()->SetTitle("z [#mum]"); if(i==0) hE2D[i]->GetZaxis()->SetTitle("E_{z} [GV/m]"); else if(i==1) hE2D[i]->GetZaxis()->SetTitle("E_{y} [GV/m]"); else if(i==2) hE2D[i]->GetZaxis()->SetTitle("E_{x} [GV/m]"); } } // --------------------------------------------------- Vertical Zoom ------------ Float_t yRange = (hE2D[index]->GetYaxis()->GetXmax() - hE2D[index]->GetYaxis()->GetXmin())/zoom; Float_t midPoint = (hE2D[index]->GetYaxis()->GetXmax() + hE2D[index]->GetYaxis()->GetXmin())/2.; Float_t yMin = midPoint-yRange/2; Float_t yMax = midPoint+yRange/2; if(pData->IsCyl()) { yMin = hE2D[index]->GetYaxis()->GetXmin(); yMax = yRange; } hE2D[index]->GetYaxis()->SetRangeUser(yMin,yMax); Float_t xMin = hE2D[index]->GetXaxis()->GetXmin(); Float_t xMax = hE2D[index]->GetXaxis()->GetXmax(); Float_t xRange = xMax - xMin; // Change the range of z axis for the fields to be symmetric. Float_t Emax = hE2D[index]->GetMaximum(); Float_t Emin = hE2D[index]->GetMinimum(); if(Emax > TMath::Abs(Emin)) Emin = -Emax; else Emax = -Emin; hE2D[index]->GetZaxis()->SetRangeUser(Emin,Emax); PPalette * plasmaPalette = (PPalette*) gROOT->FindObject("rbowwhite"); plasmaPalette->cd(); // Plotting // ----------------------------------------------- // Canvas setup TCanvas *C = new TCanvas("C","2D electric",800,500); // Actual Plotting! // ------------------------------------------------------------ // Output file TString fname; if(index<3) fname = Form("E%i",index+1); TString fOutName = Form("./%s/Plots/Field2D/Field2D-%s",sim.Data(),fname.Data()); fOutName += Form("-%s_%i",sim.Data(),time); C->cd(); // Setup Pad layout: Float_t lMargin = 0.15; Float_t rMargin = 0.18; Float_t bMargin = 0.20; Float_t tMargin = 0.06; gPad->SetLeftMargin(lMargin); gPad->SetRightMargin(rMargin); gPad->SetBottomMargin(bMargin); gPad->SetTopMargin(tMargin); if(opt.Contains("logz")) { gPad->SetLogz(1); } else { gPad->SetLogz(0); } gPad->SetFrameLineWidth(2); // Define the frames for plotting Int_t fonttype = 43; Int_t fontsize = 28; Int_t tfontsize = 30; Float_t txoffset = 1.3; Float_t lxoffset = 0.02; Float_t tyoffset = 1.0; Float_t lyoffset = 0.01; Float_t tylength = 0.02; Float_t txlength = 0.04; TH2F *hFrame = (TH2F*) gROOT->FindObject("hFrame"); if(hFrame) delete hFrame; hFrame = (TH2F*) hE2D[index]->Clone("hFrame"); hFrame->Reset(); // Format for y axis hFrame->GetYaxis()->SetTitleFont(fonttype); hFrame->GetYaxis()->SetTitleSize(tfontsize); hFrame->GetYaxis()->SetTitleOffset(tyoffset); hFrame->GetYaxis()->SetLabelFont(fonttype); hFrame->GetYaxis()->SetLabelSize(fontsize); hFrame->GetYaxis()->SetLabelOffset(lyoffset); hFrame->GetYaxis()->SetTickLength(tylength); // Format for x axis hFrame->GetXaxis()->SetTitleFont(fonttype); hFrame->GetXaxis()->SetTitleSize(tfontsize+2); hFrame->GetXaxis()->SetTitleOffset(txoffset); hFrame->GetXaxis()->SetLabelFont(fonttype); hFrame->GetXaxis()->SetLabelSize(fontsize+2); hFrame->GetXaxis()->SetLabelOffset(lxoffset); hFrame->GetXaxis()->SetTickLength(txlength); hFrame->Draw("col"); // hE2D[index]->GetZaxis()->SetNdivisions(505); hE2D[index]->GetZaxis()->SetTitleFont(fonttype); hE2D[index]->Draw("colz same"); // Re-touchs gPad->Update(); Float_t y1 = gPad->GetBottomMargin(); Float_t y2 = 1 - gPad->GetTopMargin(); Float_t x1 = gPad->GetLeftMargin(); Float_t x2 = 1 - gPad->GetRightMargin(); Float_t gap = 0.005; TPaletteAxis *palette = (TPaletteAxis*)hE2D[index]->GetListOfFunctions()->FindObject("palette"); if(palette) { palette->SetY2NDC(y2 - gap); palette->SetY1NDC(y1 + gap); palette->SetX1NDC(x2 + 0.005); palette->SetX2NDC(x2 + 0.03); palette->SetTitleOffset(tyoffset); palette->SetTitleSize(tfontsize); palette->SetLabelFont(fonttype); palette->SetLabelSize(fontsize); if(opt.Contains("logz")) palette->SetLabelOffset(0); else palette->SetLabelOffset(lyoffset); palette->SetBorderSize(2); palette->SetLineColor(1); } // Text objects TPaveText *textTime = new TPaveText(xMax - 0.30*xRange, yMax-0.10*yRange, xMax-0.02*xRange, yMax-0.02*yRange); PGlobals::SetPaveTextStyle(textTime,32); char ctext[128]; if(opt.Contains("units") && n0) sprintf(ctext,"z = %5.1f #mum", Time * skindepth / PUnits::um); else sprintf(ctext,"#omega_{p} t = %5.1f",Time); textTime->AddText(ctext); TPaveText *textDen = new TPaveText(xMin + 0.02*xRange, yMax-0.10*yRange, xMin + 0.40*xRange, yMax-0.02*yRange); PGlobals::SetPaveTextStyle(textDen,12); textDen->SetTextColor(kOrange+10); if(opt.Contains("units") && n0) { sprintf(ctext,"n_{0} = %5.2f x 10^{17} / cm^{3}", 1e-17 * n0 * PUnits::cm3); textDen->AddText(ctext); textDen->Draw(); } textTime->Draw(); gPad->RedrawAxis(); C->cd(); // Print to a file PGlobals::imgconv(C,fOutName,opt); // --------------------------------------------------------- }
int theoryStudy_separate(const TString BaseName) { TString tmpTStr; char tmpName[30],tmpName_org[30]; int Numb; TFile *f_Resbos; TFile *f_Fewz; TFile *f_Data; TFile *f_Data_PowhegErr; f_Resbos = new TFile("../../RstResbos/Resbos_"+BaseName+".root"); f_Data = new TFile("../Result"+BaseName+"/Result_"+BaseName+".root"); f_Data_PowhegErr = new TFile("../../Systematics/WptXsecErrors/"+BaseName+"Errors.root"); if (BaseName=="WpToMuNu") { f_Fewz = new TFile("../../RstFEWZ/Wp_Mu_NNLO.root"); } if (BaseName=="WmToMuNu") { f_Fewz = new TFile("../../RstFEWZ/Wm_Mu_NNLO.root"); } if (BaseName=="WpToEleNu") { f_Fewz = new TFile("../../RstFEWZ/Wp_Ele_NNLO.root"); } if (BaseName=="WmToEleNu") { f_Fewz = new TFile("../../RstFEWZ/Wm_Ele_NNLO.root"); } TH1D *hWptBins_LinScale = new TH1D("hWptBins_LinScale","hWptBins_LinScale",nBins-1,WptBins);hWptBins_LinScale->Sumw2(); TH1D *hWptBins_LogScale = new TH1D("hWptBins_LogScale","hWptBins_LogScale",nBins-1,WptLogBins);hWptBins_LogScale->Sumw2(); ///=============Reading related stat, syst errors starts here============== // TH1D* hData_StatErr = (TH1D*)f_Data_PowhegErr->Get("h_Stat")->Clone("hData_StatErr"); TH1D* hData_MetResolSystErr = (TH1D*)f_Data_PowhegErr->Get("h_met")->Clone("hData_MetResolSystErr"); TH1D* hData_EnMomScaleSystErr = (TH1D*)f_Data_PowhegErr->Get("h_scale")->Clone("hData_EnMomScaleSystErr"); TH1D* hData_EnMomSmearSystErr = (TH1D*)f_Data_PowhegErr->Get("h_smear")->Clone("hData_EnMomSmearSystErr"); TH1D* hData_QcdBckgrSystErr = (TH1D*)f_Data_PowhegErr->Get("h_qcdbckgr")->Clone("hData_QcdBckgrSystErr"); TH1D* hData_QcdShapeSystErr = (TH1D*)f_Data_PowhegErr->Get("h_qcdshape")->Clone("hData_QcdShapeSystErr"); TH1D* hData_EwkSystErr = (TH1D*)f_Data_PowhegErr->Get("h_ewk")->Clone("hData_EwkSystErr"); TH1D* hData_FsrSystErr = (TH1D*)f_Data_PowhegErr->Get("h_fsr")->Clone("hData_FsrSystErr"); TH1D* hData_SvdUnfSystErr = (TH1D*)f_Data_PowhegErr->Get("h_SvdUnf")->Clone("hData_SvdUnfSystErr"); TH1D* hData_UnfoldBiasSystErr = (TH1D*)f_Data_PowhegErr->Get("h_UnfoldBias")->Clone("hData_UnfoldBiasSystErr"); TH1D* hData_LumiSystErr = (TH1D*)f_Data_PowhegErr->Get("h_LumiSyst")->Clone("hData_LumiSystErr"); ///Lepton Reconstruction related systematic errors // TH1D* hData_EffiToySystErr = (TH1D*)f_Data_PowhegErr->Get("h_toy")->Clone("hData_EffiToySystErr"); TH1D* hData_IDIsoSigShapeSystErr = (TH1D*)f_Data_PowhegErr->Get("h_idisosig")->Clone("hData_IDIsoSigShapeSystErr"); TH1D* hData_IDIsoBkgrShapeSystErr = (TH1D*)f_Data_PowhegErr->Get("h_idisobck")->Clone("hData_IDIsoBkgrShapeSystErr"); TH1D *hData_TotalSystErr = new TH1D("hData_TotalSystErr","hData_TotalSystErr",nBins-1,WptBins);hData_TotalSystErr->Sumw2(); if(BaseName== "WpToMuNu" || BaseName== "WmToMuNu") { TH1D* hData_TrackSigShapeSystErr = (TH1D*)f_Data_PowhegErr->Get("h_tracksig")->Clone("hData_TrackSigShapeSystErr"); TH1D* hData_TrackBkgrShapeSystErr = (TH1D*)f_Data_PowhegErr->Get("h_trackbck")->Clone("hData_TrackBkgrShapeSystErr"); TH1D* hData_MuonPOGSystErr = (TH1D*)f_Data_PowhegErr->Get("h_POG")->Clone("hData_MuonPOGSystErr"); //// Calculate total syst for muon for( int ipt(1);ipt<=nBins-1;ipt++) { hData_TotalSystErr->SetBinContent(ipt, sqrt( TMath::Power(hData_TrackSigShapeSystErr->GetBinContent(ipt),2) + TMath::Power( hData_TrackBkgrShapeSystErr->GetBinContent(ipt),2) + TMath::Power( hData_MuonPOGSystErr->GetBinContent(ipt),2) + TMath::Power( hData_EffiToySystErr->GetBinContent(ipt),2)+ TMath::Power( hData_IDIsoSigShapeSystErr->GetBinContent(ipt),2)+ TMath::Power( hData_IDIsoBkgrShapeSystErr->GetBinContent(ipt),2) + TMath::Power( hData_MetResolSystErr->GetBinContent(ipt),2) + TMath::Power( hData_EnMomScaleSystErr->GetBinContent(ipt),2) + TMath::Power(hData_EnMomSmearSystErr->GetBinContent(ipt),2) + TMath::Power( hData_QcdBckgrSystErr->GetBinContent(ipt),2) + TMath::Power( hData_QcdShapeSystErr->GetBinContent(ipt),2) + TMath::Power( hData_EwkSystErr->GetBinContent(ipt),2) + TMath::Power( hData_FsrSystErr->GetBinContent(ipt),2) + TMath::Power( hData_SvdUnfSystErr->GetBinContent(ipt),2) + TMath::Power( hData_UnfoldBiasSystErr->GetBinContent(ipt),2) + TMath::Power( hData_LumiSystErr->GetBinContent(ipt),2) )); } } else if(BaseName== "WpToEleNu" || BaseName== "WmToEleNu") { TH1D* hData_BinningSystErr = (TH1D*)f_Data_PowhegErr->Get("h_bin")->Clone("hData_BinningSystErr"); //// Calculate total syst for electron for( int ipt(1);ipt<=nBins-1;ipt++) { hData_TotalSystErr->SetBinContent(ipt, sqrt( TMath::Power(hData_BinningSystErr->GetBinContent(ipt),2) + TMath::Power( hData_EffiToySystErr->GetBinContent(ipt),2) + TMath::Power( hData_IDIsoSigShapeSystErr->GetBinContent(ipt),2) + TMath::Power( hData_IDIsoBkgrShapeSystErr->GetBinContent(ipt),2) + TMath::Power( hData_MetResolSystErr->GetBinContent(ipt),2) + TMath::Power( hData_EnMomScaleSystErr->GetBinContent(ipt),2) + TMath::Power(hData_EnMomSmearSystErr->GetBinContent(ipt),2) + TMath::Power( hData_QcdBckgrSystErr->GetBinContent(ipt),2) + TMath::Power( hData_QcdShapeSystErr->GetBinContent(ipt),2) + TMath::Power( hData_EwkSystErr->GetBinContent(ipt),2) + TMath::Power( hData_FsrSystErr->GetBinContent(ipt),2) + TMath::Power( hData_SvdUnfSystErr->GetBinContent(ipt),2) + TMath::Power( hData_UnfoldBiasSystErr->GetBinContent(ipt),2) + TMath::Power( hData_LumiSystErr->GetBinContent(ipt),2) )); } } TH1D *hData_TotalUncer = new TH1D("hData_TotalUncer","hData_TotalUncer",nBins-1,WptBins);hData_TotalUncer->Sumw2(); for( int ipt(1);ipt<nBins;ipt++) { hData_TotalUncer->SetBinContent(ipt, sqrt(TMath::Power(hData_StatErr->GetBinContent(ipt),2)+ TMath::Power(hData_TotalSystErr->GetBinContent(ipt),2))); cout<<"hData_TotalUncer: "<<ipt<<"\t"<<hData_TotalUncer->GetBinContent(ipt)<<endl; } for( int ipt(1);ipt<nBins;ipt++) { //cout<<"hData_TrackSigShapeSystErr: "<<ipt<<"\t"<<hData_TrackSigShapeSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_TrackBkgrShapeSystErr: "<<ipt<<"\t"<<hData_TrackBkgrShapeSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_IDIsoSigShapeSystErr: "<<ipt<<"\t"<<hData_IDIsoSigShapeSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_IDIsoBkgrShapeSystErr: "<<ipt<<"\t"<<hData_IDIsoBkgrShapeSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_MuonPOGSystErr: "<<ipt<<"\t"<<hData_MuonPOGSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_EffiToySystErr: "<<ipt<<"\t"<<hData_EffiToySystErr->GetBinContent(ipt)<<endl; //cout<<"hData_MetResolSystErr: "<<ipt<<"\t"<<hData_MetResolSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_EnMomScaleSystErr: "<<ipt<<"\t"<<hData_EnMomScaleSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_EnMomSmearSystErr: "<<ipt<<"\t"<<hData_EnMomSmearSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_QcdBckgrSystErr: "<<ipt<<"\t"<<hData_QcdBckgrSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_QcdShapeSystErr: "<<ipt<<"\t"<<hData_QcdShapeSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_EwkSystErr: "<<ipt<<"\t"<<hData_EwkSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_FsrSystErr: "<<ipt<<"\t"<<hData_FsrSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_SvdUnfSystErr: "<<ipt<<"\t"<<hData_SvdUnfSystErr->GetBinContent(ipt)<<endl; //cout<<"hData_UnfoldBiasSystErr: "<<ipt<<"\t"<<hData_UnfoldBiasSystErr->GetBinContent(ipt)<<endl; } TH1D* hPowheg_PDFErr = (TH1D*)f_Data_PowhegErr->Get("h_PowhegPDF")->Clone("hPowheg_PDFErr"); //TH1D* hData_TotalUncer = (TH1D*)f_Data_PowhegErr->Get("h_TotalUncer")->Clone("hData_TotalUncer"); ///=============Reading related stat, syst errors Finished here============== /////==========Real Data Starts here========================================= // // Born Level RD Yield and Errors, and Converting to X sec yield and errors, making TGraph . TH1D* hData_Xsec_BornLinScale; hData_Xsec_BornLinScale = (TH1D*)f_Data->Get("BornEffCorr")->Clone("hData_Xsec_BornLinScale"); for( int ipt(1);ipt<nBins;ipt++) { hData_Xsec_BornLinScale->SetBinError(ipt, 0.01*hData_TotalUncer->GetBinContent(ipt)*hData_Xsec_BornLinScale->GetBinContent(ipt) ); } hData_Xsec_BornLinScale->Scale(1./18.429); TH1D* hData_Yield_ReconLinScale; hData_Yield_ReconLinScale = (TH1D*)f_Data->Get("data_Rec")->Clone("hData_Yield_ReconLinScale"); for( int ipt(1);ipt<nBins;ipt++) { double tmp = sqrt(hData_Yield_ReconLinScale->GetBinContent(ipt)); hData_Yield_ReconLinScale->SetBinError(ipt,tmp); } //Errors double Data_Xsec_BornStatErr[14]; double Data_Xsec_BornTotalErr[14]; for( int ipt(1);ipt<=nBins-1;ipt++) { Data_Xsec_BornStatErr[ipt] = hData_Xsec_BornLinScale->GetBinContent(ipt) * ( hData_Yield_ReconLinScale->GetBinError(ipt)/hData_Yield_ReconLinScale->GetBinContent(ipt) ); Data_Xsec_BornTotalErr[ipt] = hData_Xsec_BornLinScale->GetBinError(ipt); } // X-sex and error Log scale TH1D *hData_Xsec_BornLogScale = new TH1D("hData_Xsec_BornLogScale","hData_Xsec_BornLogScale",nBins-1,WptLogBins);hData_Xsec_BornLogScale->Sumw2(); for( int ipt(1);ipt<=nBins-1;ipt++) { hData_Xsec_BornLogScale->SetBinContent(ipt,hData_Xsec_BornLinScale->GetBinContent(ipt)/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt )); hData_Xsec_BornLogScale->SetBinError(ipt,Data_Xsec_BornTotalErr[ipt]/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt)); } /// Theory/Data ratio plot errors related to Real Data TH1D *hRatioDataErrBand = new TH1D("hRatioDataErrBand","hRatioDataErrBand",nBins-1,WptLogBins);hRatioDataErrBand->Sumw2(); TH1D *hRatioDataStatErr = new TH1D("hRatioDataStatErr","hRatioDataStatErr",nBins-1,WptLogBins);hRatioDataStatErr->Sumw2(); for( int ipt(1);ipt<=nBins-1;ipt++) { hRatioDataErrBand->SetBinContent(ipt,1.); hRatioDataErrBand->SetBinError(ipt,hData_Xsec_BornLinScale->GetBinError(ipt)/hData_Xsec_BornLinScale->GetBinContent(ipt)); hRatioDataStatErr->SetBinContent(ipt,1.); hRatioDataStatErr->SetBinError(ipt,Data_Xsec_BornStatErr[ipt]/hData_Xsec_BornLinScale->GetBinContent(ipt)); } hData_Xsec_BornLogScale->SetMarkerStyle(kFullCircle); hData_Xsec_BornLogScale->SetMarkerColor(kBlack); hData_Xsec_BornLogScale->SetMarkerSize(1); hRatioDataStatErr->SetMarkerStyle(kFullCircle); hRatioDataStatErr->SetMarkerColor(kBlack); hRatioDataStatErr->SetMarkerSize(0.6); /// TGraph TGraphErrors *Data_Xsec_Born = new TGraphErrors(hData_Xsec_BornLogScale); TGraphErrors *RatioDataErrBand = new TGraphErrors(hRatioDataErrBand); /////==========Real Data related stuff Finished here========================================= /////==========Powheg Starts here============================================== // // Born Level Powheg Yield and Errors, and Converting to X sec yield and errors, making TGraph . TH1D* hPowheg_Xsec_BornLinScale; hPowheg_Xsec_BornLinScale = (TH1D*)f_Data->Get("SVD_Born.Gen")->Clone("hPowheg_Xsec_BornLinScale"); for( int ipt(1);ipt<nBins;ipt++) { hPowheg_Xsec_BornLinScale->SetBinError(ipt, 0.01*hPowheg_PDFErr->GetBinContent(ipt)*hPowheg_Xsec_BornLinScale->GetBinContent(ipt) ); } hPowheg_Xsec_BornLinScale->Scale(1./18.429); TH1D* hPowheg_Yield_BornAfterFidCut; hPowheg_Yield_BornAfterFidCut = (TH1D*)f_Data->Get("SVD_Born.Gen")->Clone("hPowheg_Yield_BornAfterFidCut"); if(BaseName== "WpToMuNu") { hPowheg_Yield_BornAfterFidCut->Scale(1./LumiWeight_Muon_WpToMuNu_S8); } if(BaseName== "WmToMuNu") { hPowheg_Yield_BornAfterFidCut->Scale(1./LumiWeight_Muon_WmToMuNu_S8); } if(BaseName== "WpToEleNu") { hPowheg_Yield_BornAfterFidCut->Scale(1./LumiWeight_Ele_WpToEleNu_S8); } if(BaseName== "WmToEleNu") { hPowheg_Yield_BornAfterFidCut->Scale(1./LumiWeight_Ele_WmToEleNu_S8); } //Errors double Powheg_Xsec_BornStatErr[14]; double Powheg_Xsec_BornTotalErr[14]; for( int ipt(1);ipt<=nBins-1;ipt++) { Powheg_Xsec_BornStatErr[ipt] = hPowheg_Xsec_BornLinScale->GetBinContent(ipt)*sqrt(hPowheg_Yield_BornAfterFidCut->GetBinContent(ipt))/hPowheg_Yield_BornAfterFidCut->GetBinContent(ipt); Powheg_Xsec_BornTotalErr[ipt] = sqrt(Powheg_Xsec_BornStatErr[ipt]*Powheg_Xsec_BornStatErr[ipt] + hPowheg_Xsec_BornLinScale->GetBinError(ipt)*hPowheg_Xsec_BornLinScale->GetBinError(ipt)); } // X-sex and error Log scale TH1D *hPowheg_Xsec_BornLogScale = new TH1D("hPowheg_Xsec_BornLogScale","hPowheg_Xsec_BornLogScale",nBins-1,WptLogBins);hPowheg_Xsec_BornLogScale->Sumw2(); for( int ipt(1);ipt<=nBins-1;ipt++) { hPowheg_Xsec_BornLogScale->SetBinContent(ipt,hPowheg_Xsec_BornLinScale->GetBinContent(ipt)/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt)); hPowheg_Xsec_BornLogScale->SetBinError(ipt,Powheg_Xsec_BornTotalErr[ipt]/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt)); } /// Theory/Data ratio plot errors related to Real Data TH1D *hRatioPowhegStatErrBand = new TH1D("hRatioPowhegStatErrBand","hRatioPowhegStatErrBand",nBins-1,WptLogBins);hRatioPowhegStatErrBand->Sumw2(); TH1D *hRatioPowhegPDFErrBand = new TH1D("hRatioPowhegPDFErrBand","hRatioPowhegPDFErrBand",nBins-1,WptLogBins);hRatioPowhegPDFErrBand->Sumw2(); for( int ipt(1);ipt<=nBins-1;ipt++) { hRatioPowhegStatErrBand->SetBinContent(ipt,hPowheg_Xsec_BornLogScale->GetBinContent(ipt)/hData_Xsec_BornLogScale->GetBinContent(ipt)); hRatioPowhegStatErrBand->SetBinError(ipt,Powheg_Xsec_BornStatErr[ipt]/hData_Xsec_BornLinScale->GetBinContent(ipt)); hRatioPowhegPDFErrBand->SetBinContent(ipt,hPowheg_Xsec_BornLogScale->GetBinContent(ipt)/hData_Xsec_BornLogScale->GetBinContent(ipt)); hRatioPowhegPDFErrBand->SetBinError(ipt,(Powheg_Xsec_BornStatErr[ipt]/hData_Xsec_BornLinScale->GetBinContent(ipt))+(hPowheg_Xsec_BornLinScale->GetBinError(ipt)/hData_Xsec_BornLinScale->GetBinContent(ipt))); } /// TGraph TGraphErrors *Powheg_Xsec_Born = new TGraphErrors(hPowheg_Xsec_BornLogScale); TGraphErrors *RatioPowhegStatErrBand = new TGraphErrors(hRatioPowhegStatErrBand); TGraphErrors *RatioPowhegPDFErrBand = new TGraphErrors(hRatioPowhegPDFErrBand); /////==========Powheg related stuff Finished here========================================= /////==========FEWZ Starts here============================================== // // FEWZ X sec value and errors, making TGraph . TH1D* hFEWZ_Xsec_LinScale; hFEWZ_Xsec_LinScale = (TH1D*)f_Fewz->Get("hxsec")->Clone("hFEWZ_Xsec_LinScale"); //Errors TH1D* hFEWZ_Xsec_ScaleError; hFEWZ_Xsec_ScaleError = (TH1D*)f_Fewz->Get("ScaleErr")->Clone("hFEWZ_Xsec_ScaleError"); TH1D* hFEWZ_Xsec_PDFError; hFEWZ_Xsec_PDFError = (TH1D*)f_Fewz->Get("PDFErr")->Clone("hFEWZ_Xsec_PDFError"); double FEWZ_Xsec_ScaleErr[14]; double FEWZ_Xsec_PDFErr[14]; double FEWZ_Xsec_TotalErr[14]; for( int ipt(1);ipt<=nBins-1;ipt++) { FEWZ_Xsec_ScaleErr[ipt] = 0.01*hFEWZ_Xsec_ScaleError->GetBinError(ipt)*hFEWZ_Xsec_LinScale->GetBinContent(ipt); FEWZ_Xsec_PDFErr[ipt] = 0.01*hFEWZ_Xsec_PDFError->GetBinError(ipt)*hFEWZ_Xsec_LinScale->GetBinContent(ipt); FEWZ_Xsec_TotalErr[ipt] = sqrt( FEWZ_Xsec_ScaleErr[ipt]*FEWZ_Xsec_ScaleErr[ipt] + FEWZ_Xsec_PDFErr[ipt]*FEWZ_Xsec_PDFErr[ipt] ); } // X-sex and error Log scale TH1D *hFEWZ_Xsec_LogScale = new TH1D("hFEWZ_Xsec_LogScale","hFEWZ_Xsec_LogScale",nBins-1,WptLogBins);hFEWZ_Xsec_LogScale->Sumw2(); for( int ipt(1);ipt<=nBins-1;ipt++) { hFEWZ_Xsec_LogScale->SetBinContent(ipt,hFEWZ_Xsec_LinScale->GetBinContent(ipt)/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt)); hFEWZ_Xsec_LogScale->SetBinError(ipt,FEWZ_Xsec_TotalErr[ipt]/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt)); } /// Theory/Data ratio plot errors related to Real Data TH1D *hRatioFEWZStatErrBand = new TH1D("hRatioFEWZStatErrBand","hRatioFEWZStatErrBand",nBins-1,WptLogBins);hRatioFEWZStatErrBand->Sumw2(); TH1D *hRatioFEWZScaleErr = new TH1D("hRatioFEWZScaleErr","hRatioFEWZScaleErr",nBins-1,WptLogBins);hRatioFEWZScaleErr->Sumw2(); TH1D *hRatioFEWZQCDScaleErrBand = new TH1D("hRatioFEWZQCDScalePDFErrBand","hRatioFEWZQCDScalePDFErrBand",nBins-1,WptLogBins);hRatioFEWZQCDScalePDFErrBand->Sumw2(); TH1D *hRatioFEWZScalePDFErrBand = new TH1D("hRatioFEWZScalePDFErrBand","hRatioFEWZScalePDFErrBand",nBins-1,WptLogBins);hRatioFEWZScalePDFErrBand->Sumw2(); for( int ipt(1);ipt<=nBins-1;ipt++) { hRatioFEWZStatErrBand->SetBinContent(ipt,hFEWZ_Xsec_LogScale->GetBinContent(ipt)/hData_Xsec_BornLogScale->GetBinContent(ipt)); hRatioFEWZStatErrBand->SetBinError(ipt,0.01); hRatioFEWZScaleErr->SetBinContent(ipt,hFEWZ_Xsec_LogScale->GetBinContent(ipt)/hData_Xsec_BornLogScale->GetBinContent(ipt)); hRatioFEWZScaleErr->SetBinError(ipt,FEWZ_Xsec_ScaleErr[ipt]/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt)); hRatioFEWZQCDScaleErrBand->SetBinContent(ipt,hFEWZ_Xsec_LogScale->GetBinContent(ipt)/hData_Xsec_BornLogScale->GetBinContent(ipt)); hRatioFEWZQCDScaleErrBand->SetBinError(ipt,0.01 + hRatioFEWZScaleErr->GetBinError(ipt)/hData_Xsec_BornLogScale->GetBinContent(ipt)); hRatioFEWZScalePDFErrBand->SetBinContent(ipt,hFEWZ_Xsec_LogScale->GetBinContent(ipt)/hData_Xsec_BornLogScale->GetBinContent(ipt)); hRatioFEWZScalePDFErrBand->SetBinError(ipt,0.01+(hFEWZ_Xsec_LogScale->GetBinError(ipt)+hRatioFEWZScaleErr->GetBinError(ipt))/hData_Xsec_BornLogScale->GetBinContent(ipt)); } /// TGraph TGraphErrors *FEWZ_Xsec = new TGraphErrors(hFEWZ_Xsec_LogScale); TGraphErrors* RatioFEWZStatErrBand = new TGraphErrors(hRatioFEWZStatErrBand); TGraphErrors* RatioFEWZQCDScaleErrBand = new TGraphErrors(hRatioFEWZQCDScaleErrBand); TGraphErrors* RatioFEWZScalePDFErrBand = new TGraphErrors(hRatioFEWZScalePDFErrBand); /////==========FEWZ related stuff Finished here========================================= /////==========ResBos Starts here============================================== // // ResBos X sec value and errors, making TGraph . TH1D* hResBos30_CentralYield_LinScale; hResBos30_CentralYield_LinScale = (TH1D*)f_Resbos->Get("hResbos30")->Clone("hResBos30_CentralYield_LinScale"); TH1D* AllResbos[7]; for( int i(0);i<7;i++) { Numb = 29+i; sprintf(tmpName_org,"hResbos%d",Numb); sprintf(tmpName,"AllResbos_%d",i); AllResbos[i] = (TH1D*)f_Resbos->Get(tmpName_org)->Clone(tmpName); } //Errors Double_t Resb_errMax[nBins-1]; Double_t Resb_errMin[nBins-1]; double tmpVal,tmpDiff; for( int ipt(0);ipt<nBins-1;ipt++) { double nomVal = AllResbos[1]->GetBinContent(ipt+1); Resb_errMax[ipt] = -99999; Resb_errMin[ipt] = 990009; for (int i(0);i<7;i++) { tmpVal = AllResbos[i]->GetBinContent(ipt+1); tmpDiff = tmpVal - nomVal; if( tmpDiff > Resb_errMax[ipt] ) Resb_errMax[ipt] = tmpDiff; if( tmpDiff < Resb_errMin[ipt] ) Resb_errMin[ipt] = tmpDiff; } if (Resb_errMax[ipt] < 0) Resb_errMax[ipt] = 0.; if (Resb_errMin[ipt] > 0) Resb_errMin[ipt] = 0.; if (Resb_errMin[ipt] < 0) Resb_errMin[ipt] = -Resb_errMin[ipt]; Resb_errMax[ipt] = Resb_errMax[ipt]/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt+1); Resb_errMin[ipt] = Resb_errMin[ipt]/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt+1); } // X-sex and error Log scale TH1D *hResBos30_CentralYield_LogScale = new TH1D("hResBos30_CentralYield_LogScale","hResBos30_CentralYield_LogScale",nBins-1,WptLogBins);hResBos30_CentralYield_LogScale->Sumw2(); Double_t hResb30_CentralXsec[nBins-1]; Double_t RatioResbVal[nBins-1],errResbosDataLo[nBins-1],errResbosDataHi[nBins-1]; for( int ipt(0);ipt<nBins-1;ipt++) { hResBos30_CentralYield_LogScale->SetBinContent(ipt+1,hResBos30_CentralYield_LinScale->GetBinContent(ipt+1)/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt+1) ); hResb30_CentralXsec[ipt] = hResBos30_CentralYield_LinScale->GetBinContent(ipt+1)/hWptBins_LinScale->GetXaxis()->GetBinWidth(ipt+1); RatioResbVal[ipt]=hResBos30_CentralYield_LogScale->GetBinContent(ipt+1)/hData_Xsec_BornLogScale->GetBinContent(ipt+1); errResbosDataLo[ipt]=Resb_errMin[ipt]/hData_Xsec_BornLogScale->GetBinContent(ipt+1); errResbosDataHi[ipt]=Resb_errMax[ipt]/hData_Xsec_BornLogScale->GetBinContent(ipt+1); } /// Theory/Data ratio plot errors related to Real Data TGraphAsymmErrors *Resb30_CentralXsec = new TGraphAsymmErrors(nBins-1, ax, hResb30_CentralXsec, aex, aex, Resb_errMin, Resb_errMax); TGraphAsymmErrors *RatioResbosErrBand = new TGraphAsymmErrors(nBins-1, ax, RatioResbVal, aex, aex, errResbosDataLo, errResbosDataHi); /////==========ResBos related stuff Finished here========================================= //// Now design and Draw //Data RatioDataErrBand->SetFillColor(kBlack); RatioDataErrBand->SetFillStyle(3354); //Powheg Powheg_Xsec_Born->SetFillColor(kRed); Powheg_Xsec_Born->SetFillStyle(3345); RatioPowhegStatErrBand->SetFillColor(kRed-10); RatioPowhegStatErrBand->SetFillStyle(3001); RatioPowhegPDFErrBand->SetFillColor(kRed+2); RatioPowhegPDFErrBand->SetFillStyle(3001); //FEWZ FEWZ_Xsec->SetFillColor(kGreen); FEWZ_Xsec->SetFillStyle(3444); RatioFEWZStatErrBand->SetFillColor(kGreen); RatioFEWZStatErrBand->SetFillStyle(3001); RatioFEWZQCDScaleErrBand->SetFillColor(kGreen+7); RatioFEWZQCDScaleErrBand->SetFillStyle(3001); RatioFEWZScalePDFErrBand->SetFillColor(kGreen+3); RatioFEWZScalePDFErrBand->SetFillStyle(3001); //ResBos Resb30_CentralXsec->SetFillColor(kBlue); Resb30_CentralXsec->SetFillStyle(3354); RatioResbosErrBand->SetFillColor(kBlue-7); RatioResbosErrBand->SetFillStyle(3001); TLegend *lL =new TLegend(0.2,0.2,0.52,0.38); lL->SetFillColor(0); lL->SetBorderSize(0); lL->AddEntry(Data_Xsec_Born,"data","PL"); lL->AddEntry(Powheg_Xsec_Born,"POWHEG CT10 NLO","f"); lL->AddEntry(FEWZ_Xsec,"FEWZ CT10 NNLO","f"); lL->AddEntry(Resb30_CentralXsec,"ResBos CT10 NNLL","f"); TPaveText *tb = new TPaveText(0.2,0.39,0.52,0.5,"NDC"); tb->SetBorderSize(0); tb->SetFillStyle(0); tb->AddText("18.4 pb^{-1} at #sqrt{s} = 8 TeV"); if (BaseName=="WpToMuNu") tb->AddText("W^{+} #rightarrow #mu^{+} #nu"); if (BaseName=="WmToMuNu") tb->AddText("W^{-} #rightarrow #mu^{-} #bar{#nu}"); if (BaseName=="WpToEleNu") tb->AddText("W^{+} #rightarrow e^{+} #nu"); if (BaseName=="WmToEleNu") tb->AddText("W^{-} #rightarrow e^{-} #bar{#nu}"); TCanvas *lC1 = new TCanvas("Can","Can",800,840); lC1->cd(); lC1->SetLogy(); lC1->cd(1)->SetPad(0,0.05,0.95,1.0); lC1->cd(1)->SetTopMargin(0.05); lC1->cd(1)->SetBottomMargin(0.1); lC1->cd(1)->SetLeftMargin(0.15); lC1->cd(1)->SetRightMargin(0.07); lC1->cd(1)->SetTickx(1); lC1->cd(1)->SetTicky(1); gStyle->SetLineWidth(2.); gStyle->SetOptStat(0); gStyle->SetHatchesSpacing(0.75); gStyle->SetHatchesLineWidth(2); gPad->SetLogx(1); gPad->SetLogy(1); Powheg_Xsec_Born->GetYaxis()->SetRangeUser(1e-3,5*hResb30_CentralXsec[0]); Powheg_Xsec_Born->SetTitle(""); Powheg_Xsec_Born->GetYaxis()->SetTitle("d#sigma/dp_{T}^{W} [pb/GeV]"); Powheg_Xsec_Born->GetYaxis()->SetTitleOffset(1.8); Powheg_Xsec_Born->GetXaxis()->SetTitle("p_{T}^{W} [GeV]"); TPaveText *cmspre = new TPaveText(0.63,0.95,0.95,0.99,"NDC"); cmspre->SetBorderSize(0); cmspre->SetFillStyle(0); cmspre->AddText("CMS Preliminary"); Powheg_Xsec_Born->Draw("A2"); FEWZ_Xsec->Draw("2"); Resb30_CentralXsec->Draw("2"); Data_Xsec_Born->Draw("p"); lL->Draw(); tb->Draw(); cmspre->Draw(); if(BaseName=="WpToMuNu") sprintf(tmpName,"wpmnCrossSec.png"); if(BaseName=="WmToMuNu") sprintf(tmpName,"wmmnCrossSec.png"); if(BaseName=="WpToEleNu") sprintf(tmpName,"wpenCrossSec.png"); if(BaseName=="WmToEleNu") sprintf(tmpName,"wmenCrossSec.png"); lC1->SaveAs(tmpName); TCanvas *lC2 = new TCanvas("Can","Can",800,800); lC2->cd(); lC2->SetLogy(); lC2->Divide(1,3,0,0); lC2->cd(1)->SetPad(0,0.67,0.95,0.95); lC2->cd(1)->SetTopMargin(0.15); lC2->cd(1)->SetBottomMargin(0.01); lC2->cd(1)->SetLeftMargin(0.15); lC2->cd(1)->SetRightMargin(0.07); lC2->cd(1)->SetTickx(1); lC2->cd(1)->SetTicky(1); lC2->cd(1)->SetLogx(1); TPaveText *tb1 = new TPaveText(0.15,0.72,0.35,0.82,"NDC"); tb1->SetBorderSize(0); tb1->SetFillStyle(0); tb1->SetTextSize(0.12); tb1->AddText("ResBos"); TLegend *rL1 =new TLegend(0.2,0.1,0.58,0.30); rL1->SetFillColor(0); rL1->SetBorderSize(0); rL1-> SetNColumns(2); rL1->AddEntry(RatioResbosErrBand,"Theory syst","F"); rL1->AddEntry(hRatioDataStatErr,"Data stat","PLE1"); hRatioDataStatErr->SetTitle(""); rL1->AddEntry(hRatioDataStatErr,"",""); rL1->AddEntry(RatioDataErrBand,"Data stat+syst","F"); rL1->SetTextSize(0.07); TLegend *tL1 =new TLegend(0.17,0.72,0.37,0.82); tL1->SetFillColor(0); tL1->SetBorderSize(0); tL1->AddEntry(RatioResbosErrBand,"ResBos","F"); tL1->SetTextSize(0.12); tL1->SetTextFont(2); TPaveText *cmspre2 = new TPaveText(0.05,0.92,0.85,0.99,"NDC"); cmspre2->SetBorderSize(0); cmspre2->SetFillStyle(0); cmspre2->SetTextSize(0.10); cmspre2->AddText("CMS Preliminary, 18.4 pb^{-1} at #sqrt{s} = 8 TeV"); TPaveText *tb4 = new TPaveText(0.35,0.72,0.67,0.83,"NDC"); tb4->SetBorderSize(0); tb4->SetFillStyle(0); if (BaseName=="WpToMuNu") tb4->AddText("W^{+} #rightarrow #mu^{+} #nu"); if (BaseName=="WmToMuNu") tb4->AddText("W^{-} #rightarrow #mu^{-} #bar{#nu}"); if (BaseName=="WpToEleNu") tb4->AddText("W^{+} #rightarrow e^{+} #nu"); if (BaseName=="WmToEleNu") tb4->AddText("W^{-} #rightarrow e^{-} #bar{#nu}"); drawDifference(hResBos30_CentralYield_LogScale, hData_Xsec_BornLogScale, hRatioDataErrBand, RatioPowhegStatErrBand,1,RatioPowhegStatErrBand,RatioResbosErrBand,hRatioDataStatErr,RatioFEWZQCDScaleErrBand); rL1->Draw(); //tb1->Draw(); tL1->Draw(); tb4->Draw(); cmspre2->Draw(); lC2->cd(2)->SetPad(0,0.37,0.95,0.65); lC2->cd(2)->SetTopMargin(0.01); lC2->cd(2)->SetBottomMargin(0.01); lC2->cd(2)->SetLeftMargin(0.15); lC2->cd(2)->SetRightMargin(0.07); lC2->cd(2)->SetTickx(1); lC2->cd(2)->SetTicky(1); lC2->cd(2)->SetLogx(1); TPaveText *tb2 = new TPaveText(0.15,0.82,0.35,0.92,"NDC"); tb2->SetBorderSize(0); tb2->SetFillStyle(0); tb2->SetTextSize(0.12); tb2->AddText("Powheg"); TLegend *rL2 =new TLegend(0.2,0.05,0.68,0.30); rL2->SetFillColor(0); rL2->SetBorderSize(0); rL2-> SetNColumns(2); rL2->AddEntry(RatioPowhegPDFErrBand,"PDF ","F"); rL2->AddEntry(hRatioDataStatErr,"Data stat","PLE1"); rL2->AddEntry(RatioPowhegStatErrBand,"stat","F"); rL2->AddEntry(RatioDataErrBand,"Data stat+syst","F"); rL2->SetTextSize(0.07); TLegend *tL2 =new TLegend(0.17,0.85,0.37,0.95); tL2->SetFillColor(0); tL2->SetBorderSize(0); tL2->AddEntry(RatioPowhegPDFErrBand,"POWHEG","F"); tL2->SetTextSize(0.12); tL2->SetTextFont(2); //drawDifference(hPowhegLog,hDataLog,hDataErrBand,pRatio,2,pRatioPDF,ResbosErrBand,hStatErr,fScaleRatio); //drawDifference(Powheg_Xsec_Born,hData_Xsec_BornLogScale,hRatioDataErrBand,RatioPowhegStatErrBand,2,RatioPowhegPDFErrBand,RatioResbosErrBand,hRatioDataStatErr,RatioFEWZQCDScaleErrBand); drawDifference(hPowheg_Xsec_BornLogScale,hData_Xsec_BornLogScale,hRatioDataErrBand,RatioPowhegStatErrBand,2,RatioPowhegPDFErrBand,RatioResbosErrBand,hRatioDataStatErr,RatioFEWZQCDScaleErrBand); rL2->Draw(); tL2->Draw(); lC2->cd(3)->SetPad(0,0.07,0.95,0.35); lC2->cd(3)->SetTopMargin(0.01); lC2->cd(3)->SetBottomMargin(0.05); lC2->cd(3)->SetLeftMargin(0.15); lC2->cd(3)->SetRightMargin(0.07); lC2->cd(3)->SetTickx(1); lC2->cd(3)->SetTicky(1); lC2->cd(3)->SetLogx(1); TPaveText *tb3 = new TPaveText(0.15,0.82,0.35,0.92,"NDC"); tb3->SetBorderSize(0); tb3->SetFillStyle(0); tb3->SetTextSize(0.12); tb3->AddText("Fewz"); TLegend *rL3 =new TLegend(0.2,0.1,0.58,0.30); rL3->SetFillColor(0); rL3->SetBorderSize(0); rL3-> SetNColumns(2); rL3->AddEntry(RatioFEWZScalePDFErrBand,"PDF","F"); rL3->AddEntry(hRatioDataStatErr,"Data stat","PLE1"); rL3->AddEntry(RatioFEWZQCDScaleErrBand,"QCD scales","F"); rL3->AddEntry(RatioDataErrBand,"Data stat+syst","F"); rL3->AddEntry(RatioFEWZStatErrBand,"stat","F"); rL3->SetTextSize(0.07); TLegend *tL3 =new TLegend(0.17,0.85,0.37,0.95); tL3->SetFillColor(0); tL3->SetBorderSize(0); tL3->AddEntry(RatioFEWZScalePDFErrBand,"FEWZ","F"); tL3->SetTextSize(0.12); tL3->SetTextFont(2); drawDifference(hFEWZ_Xsec_LogScale,hData_Xsec_BornLogScale,hRatioDataErrBand,RatioFEWZStatErrBand,3,RatioFEWZScalePDFErrBand,RatioResbosErrBand,hRatioDataStatErr,RatioFEWZQCDScaleErrBand); rL3->Draw(); tL3->Draw(); if(BaseName=="WpToMuNu") sprintf(tmpName,"wpmnRatioTheoData.png"); if(BaseName=="WmToMuNu") sprintf(tmpName,"wmmnRatioTheoData.png"); if(BaseName=="WpToEleNu") sprintf(tmpName,"wpenRatioTheoData.png"); if(BaseName=="WmToEleNu") sprintf(tmpName,"wmenRatioTheoData.png"); lC2->SaveAs(tmpName); return 0; }
{ // //This macro produces the flowchart of TFormula::Analyze //Author: Rene Brun gROOT->Reset(); c1 = new TCanvas("c1","Analyze.mac",620,790); c1->Range(-1,0,19,30); TPaveLabel pl1(0,27,3.5,29,"Analyze"); pl1.SetFillColor(42); pl1.Draw(); TPaveText pt1(0,22.8,4,25.2); TText *t1=pt1.AddText("Parenthesis matching"); TText *t2=pt1.AddText("Remove unnecessary"); TText *t2a=pt1.AddText("parenthesis"); pt1.Draw(); TPaveText pt2(6,23,10,25); TText *t3=pt2.AddText("break of"); TText *t4=pt2.AddText("Analyze"); pt2.Draw(); TPaveText pt3(0,19,4,21); t4=pt3.AddText("look for simple"); TText *t5=pt3.AddText("operators"); pt3.Draw(); TPaveText pt4(0,15,4,17); TText *t6=pt4.AddText("look for an already"); TText *t7=pt4.AddText("defined expression"); pt4.Draw(); TPaveText pt5(0,11,4,13); TText *t8=pt5.AddText("look for usual"); TText *t9=pt5.AddText("functions :cos sin ..");
void proj_npe_7() { //=========Macro generated from canvas: c/ //========= (Wed Jul 15 10:08:15 2015) by ROOT version6.04/00 TCanvas *c = new TCanvas("c", "",0,45,600,500); c->SetHighLightColor(2); c->Range(-2716.773,-19.2575,4381.788,173.3175); c->SetFillColor(0); c->SetBorderMode(0); c->SetBorderSize(2); c->SetFrameBorderMode(0); c->SetFrameBorderMode(0); Double_t _fx8[40] = { -1533.68, -1080.366, -985.4475, -967.7257, -676.2766, -543.2768, 0.5077484, 1.609375, 4, 230.4228, 298.6529, 327.7793, 383.4035, 536.5637, 668.7969, 863.9145, 907.8805, 964.7188, 971.6563, 1075.914, 1097.936, 1215.826, 1275.258, 1308.524, 1328.116, 1732.736, 2102.711, 2197.457, 2255.99, 2286.444, 2371.061, 2594.067, 2630.891, 2704.654, 2727.792, 2773.388, 2784.73, 2845.592, 2924.958, 3198.695}; Double_t _fy8[40] = { 2.75, 2.65, 2.65, 2.7, 2.35, 2.45, 140.25, 2.65, 2.15, 2.55, 2.35, 2.45, 2.3, 2.5, 2.65, 4.05, 2.55, 2.5, 2.35, 2.25, 2.6, 2.7, 2.7, 2.6, 2.4, 2.35, 2.8, 2.55, 2.35, 2.8, 2.4, 2.35, 2.6, 2.6, 2.45, 2.45, 2.65, 2.55, 2.55, 2.65}; TGraph *graph = new TGraph(40,_fx8,_fy8); graph->SetName(""); graph->SetTitle("npe values of flashes in event: 7"); graph->SetFillColor(1); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#0000ff"); graph->SetMarkerColor(ci); graph->SetMarkerStyle(20); TH1F *Graph_Graph8 = new TH1F("Graph_Graph8","npe values of flashes in event: 7",100,-2006.917,3671.932); Graph_Graph8->SetMinimum(0); Graph_Graph8->SetMaximum(154.06); Graph_Graph8->SetDirectory(0); Graph_Graph8->SetStats(0); ci = TColor::GetColor("#000099"); Graph_Graph8->SetLineColor(ci); Graph_Graph8->GetXaxis()->SetTitle("flash_t"); Graph_Graph8->GetXaxis()->SetLabelFont(42); Graph_Graph8->GetXaxis()->SetLabelSize(0.035); Graph_Graph8->GetXaxis()->SetTitleSize(0.035); Graph_Graph8->GetXaxis()->SetTitleFont(42); Graph_Graph8->GetYaxis()->SetTitle("flash_npe"); Graph_Graph8->GetYaxis()->SetLabelFont(42); Graph_Graph8->GetYaxis()->SetLabelSize(0.035); Graph_Graph8->GetYaxis()->SetTitleSize(0.035); Graph_Graph8->GetYaxis()->SetTitleFont(42); Graph_Graph8->GetZaxis()->SetLabelFont(42); Graph_Graph8->GetZaxis()->SetLabelSize(0.035); Graph_Graph8->GetZaxis()->SetTitleSize(0.035); Graph_Graph8->GetZaxis()->SetTitleFont(42); graph->SetHistogram(Graph_Graph8); graph->Draw("ap"); TPaveText *pt = new TPaveText(0.1823077,0.9368947,0.8176923,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); TText *AText = pt->AddText("npe values of flashes in event: 7"); pt->Draw(); c->Modified(); c->cd(); c->SetSelected(c); }
void PlotField1D( const TString &sim, Int_t time, Int_t Nbins=1, const TString &options="") { #ifdef __CINT__ gSystem->Load("libplasma.so"); #endif PlasmaGlob::Initialize(); TString opt = options; gStyle->SetPadLeftMargin(0.10); // Margin left axis gStyle->SetPadRightMargin(0.12); // Margin right axis if(opt.Contains("grid")) { gStyle->SetPadGridX(1); gStyle->SetPadGridY(1); } // Load PData PData *pData = PData::Get(sim.Data()); pData->LoadFileNames(time); if(!pData->IsInit()) return; Bool_t CYL = kFALSE; if(sim.Contains("cyl")) { CYL = kTRUE; opt += "cyl"; } Bool_t ThreeD = kFALSE; if(sim.Contains("3D")) ThreeD = kTRUE; // Some plasma constants Double_t n0 = pData->GetPlasmaDensity(); Double_t kp = pData->GetPlasmaK(); Double_t skindepth = 1/kp; Double_t E0 = pData->GetPlasmaE0(); // Some beam properties: Float_t Ebeam = pData->GetBeamEnergy() * PUnits::MeV; Float_t gamma = Ebeam / PConst::ElectronMassE; Float_t vbeam = TMath::Sqrt(1 - 1/(gamma*gamma)); // cout << Form(" - Bunch gamma = %8.4f", gamma ) << endl; // cout << Form(" - Bunch velocity = %8.4f c", vbeam ) << endl; Float_t Time = pData->GetRealTime(); // z start of the plasma in normalized units. Float_t zStartPlasma = pData->GetPlasmaStart()*kp; // z start of the beam in normalized units. Float_t zStartBeam = pData->GetBeamStart()*kp; Time -= zStartPlasma - zStartBeam; // 1D histograms TString opth1 = opt; opth1 += "avg"; // Get electric fields const Int_t Nfields = 1; TH1F **hE1D = new TH1F*[Nfields]; for(Int_t i=0;i<Nfields;i++) { hE1D[i] = NULL; if(!pData->GetEfieldFileName(i)) continue; char nam[3]; sprintf(nam,"e%i",i+1); if(ThreeD) { if(i==0) hE1D[i] = pData->GetH1SliceZ3D(pData->GetEfieldFileName(i)->c_str(),nam,-1,Nbins,-1,Nbins,opth1.Data()); else hE1D[i] = pData->GetH1SliceZ3D(pData->GetEfieldFileName(i)->c_str(),nam,-Nbins,Nbins,-Nbins,Nbins,opth1.Data()); } else if(CYL) { // Cylindrical: The firt bin with r>0 is actually the number 1 (not the 0). if(i==0) hE1D[i] = pData->GetH1SliceZ(pData->GetEfieldFileName(i)->c_str(),nam,1,Nbins,opth1.Data()); else hE1D[i] = pData->GetH1SliceZ(pData->GetEfieldFileName(i)->c_str(),nam,1,Nbins,opth1.Data()); } else { // 2D cartesian if(i==0) hE1D[i] = pData->GetH1SliceZ(pData->GetEfieldFileName(i)->c_str(),nam,-1,Nbins,opth1.Data()); else hE1D[i] = pData->GetH1SliceZ(pData->GetEfieldFileName(i)->c_str(),nam,-Nbins,Nbins,opth1.Data()); } char hName[24]; sprintf(hName,"hE_%i",i); hE1D[i]->SetName(hName); if(opt.Contains("comov")) hE1D[i]->GetXaxis()->SetTitle("#zeta [c/#omega_{p}]"); else hE1D[i]->GetXaxis()->SetTitle("z [c/#omega_{p}]"); if(i==0) hE1D[i]->GetYaxis()->SetTitle("E_{z} [E_{0}]"); else if(i==1) hE1D[i]->GetYaxis()->SetTitle("E_{y} [E_{0}}]"); else if(i==2) hE1D[i]->GetYaxis()->SetTitle("E_{x} [E_{0}}]"); } // Chaning to user units: if(opt.Contains("units") && n0) { for(Int_t i=0;i<Nfields;i++) { Int_t NbinsX = hE1D[i]->GetNbinsX(); Float_t xMin = (skindepth/PUnits::mm) * hE1D[i]->GetXaxis()->GetXmin(); Float_t xMax = (skindepth/PUnits::mm) * hE1D[i]->GetXaxis()->GetXmax(); hE1D[i]->SetBins(NbinsX,xMin,xMax); for(Int_t j=0;j<NbinsX;j++) { hE1D[i]->SetBinContent(j, hE1D[i]->GetBinContent(j) * ( E0 / (PUnits::GV/PUnits::m) ) ); } if(opt.Contains("comov")) hE1D[i]->GetXaxis()->SetTitle("#zeta [mm]"); else hE1D[i]->GetXaxis()->SetTitle("z [mm]"); if(i==0) hE1D[i]->GetYaxis()->SetTitle("E_{z} [GV/m]"); else if(i==1) hE1D[i]->GetYaxis()->SetTitle("E_{y} [GV/m]"); else if(i==2) hE1D[i]->GetYaxis()->SetTitle("E_{x} [GV/m]"); } } // Calculate wave positions: // ---------------------------------------------------------------- // Retrieve the previous time TGraph if any; // Open TGraph TString filename = Form("./%s/Plots/Field1D/Field1D-%s.root",sim.Data(),sim.Data()); TFile * ifile = (TFile*) gROOT->GetListOfFiles()->FindObject(filename); // if doesn't exist the directory should be created if (!ifile) { TString f = filename; TString dir2 = f.Remove( f.Last( '/' ), f.Length() - f.Last( '/' ) ); TString dir1 = f.Remove( f.Last( '/' ), f.Length() - f.Last( '/' ) ); gSystem->mkdir( dir1 ); gSystem->mkdir( dir2 ); ifile = new TFile(filename,"UPDATE"); } Float_t *EMaxPos = new Float_t[Nfields]; Float_t *EMaxValue = new Float_t[Nfields]; // Get the Graph with the x1 positions of the maximum E_1 TGraph **graph = new TGraph*[Nfields]; char gName[24]; for(Int_t i=0;i<Nfields;i++) { if(!hE1D[i]) continue; EMaxPos[i] = EMaxValue[i] = -999; // Initial time search window: Float_t xCenter = (hE1D[i]->GetXaxis()->GetXmin()+hE1D[i]->GetXaxis()->GetXmax())/2.; Float_t xs1min = 0.5*(hE1D[i]->GetXaxis()->GetXmin()+xCenter); Float_t xs1max = xCenter; // For focusing fields i==1,2 we use a narrower window based on the previosly found // minimum for the accelerating fields i==0. if(i>0) { xCenter = EMaxPos[0]; if(opt.Contains("units") && n0) { xs1min = xCenter - (0.25*TMath::Pi() * 1e3 * skindepth); xs1max = xCenter + (0.25*TMath::Pi() * 1e3 * skindepth); } else { xs1min = xCenter - 0.25*TMath::Pi(); xs1max = xCenter + 0.25*TMath::Pi(); } } sprintf(gName,"gEMaxPos_%i",i); graph[i] = (TGraph*) ifile->Get(gName); if(graph[i]) { Double_t *y = graph[i]->GetY(); // Setup the searching windows to +/- pi/2 respect the last found minimum. if(opt.Contains("units") && n0) { xs1min = y[graph[i]->GetN()-1] - (0.5*TMath::Pi() * 1e3 * skindepth); xs1max = y[graph[i]->GetN()-1] + (0.5*TMath::Pi() * 1e3 * skindepth); } else { xs1min = y[graph[i]->GetN()-1] - 0.5*TMath::Pi(); xs1max = y[graph[i]->GetN()-1] + 0.5*TMath::Pi(); } delete graph[i]; } TH1F *htemp = (TH1F*) hE1D[i]->Clone("htemp"); htemp->GetXaxis()->SetRangeUser(xs1min,xs1max); //htemp->Smooth(1,"R"); Int_t binMax = htemp->GetMinimumBin(); EMaxPos[i] = (Float_t) htemp->GetBinCenter(binMax); EMaxValue[i] = (Float_t) htemp->GetBinContent(binMax); delete htemp; } // Tunning the Histograms // --------------------- // Plotting // ----------------------------------------------- // Output file TString fOutName = Form("./%s/Plots/Field1D/Field1D",sim.Data()); fOutName += Form("-%s_%i",sim.Data(),time); // Canvas setup TCanvas *C = new TCanvas("C","Electric wakefield on axis",850,1000); C->Divide(1,2); // Draw objects TPaveText *textTime = new TPaveText(0.70,0.87,0.85,0.92,"NDC"); PlasmaGlob::SetPaveTextStyle(textTime); char ctext[128]; if(opt.Contains("units") && n0) sprintf(ctext,"Z = %5.1f mm", 1e3 * skindepth * Time); else sprintf(ctext,"T = %5.1f 1/#omega_{p}",Time); textTime->AddText(ctext); // Colors Int_t fieldC = PlasmaGlob::fieldLine; Int_t phaseC = kGray+1; // Actual Plotting! // ------------------------------------------------------------ // More makeup C->cd(1); gPad->SetGridy(0); gPad->SetGridx(0); gPad->SetFrameLineWidth(2); hE1D[0]->SetLineWidth(1); hE1D[0]->GetYaxis()->CenterTitle(); hE1D[0]->GetXaxis()->CenterTitle(); hE1D[0]->SetLineStyle(1); hE1D[0]->SetLineWidth(3); hE1D[0]->SetLineColor(fieldC); hE1D[0]->SetMarkerStyle(20); if(Nfields>1) { hE1D[1]->GetYaxis()->CenterTitle(); hE1D[1]->GetXaxis()->CenterTitle(); hE1D[1]->SetLineStyle(1); hE1D[1]->SetLineWidth(1); hE1D[1]->SetLineColor(fieldC); hE1D[1]->SetMarkerStyle(24); } Float_t factor = 1.5; Float_t minimum = factor * hE1D[0]->GetMinimum(); Float_t maximum = factor * hE1D[0]->GetMaximum(); if(Nfields>1) { if(hE1D[1]->GetMaximum() > hE1D[0]->GetMaximum()) { maximum = factor * hE1D[1]->GetMaximum(); } if(hE1D[1]->GetMinimum() < hE1D[0]->GetMinimum()) { minimum = factor * hE1D[1]->GetMinimum(); } } if( maximum >= TMath::Abs(minimum)) minimum = -maximum; else maximum = - minimum; hE1D[0]->GetYaxis()->SetRangeUser(minimum,maximum); hE1D[0]->Draw("C"); if(Nfields>1) hE1D[1]->Draw("C same"); C->Update(); TLine *line0 = new TLine(hE1D[0]->GetXaxis()->GetXmin(), (gPad->GetUymin()+gPad->GetUymax())/2., hE1D[0]->GetXaxis()->GetXmax(), (gPad->GetUymin()+gPad->GetUymax())/2.); line0->SetLineColor(kGray+1); line0->SetLineStyle(2); line0->Draw(); TMarker *markEMax0 = new TMarker(EMaxPos[0],EMaxValue[0], 24); markEMax0->SetMarkerColor(fieldC); markEMax0->SetMarkerSize(1.6); markEMax0->Draw(); if(Nfields>1) { TMarker *markEMax1 = new TMarker(EMaxPos[1],EMaxValue[1], 24); markEMax1->SetMarkerColor(fieldC); markEMax1->SetMarkerSize(1.4); markEMax1->Draw(); } textTime->Draw(); // ---- // Define the TGraphs Int_t nPoints = 0; TGraph **gEMaxPos = new TGraph*[Nfields]; TGraph **gEMaxValue = new TGraph*[Nfields]; for(Int_t i=0;i<Nfields;i++) { if(!hE1D[i]) continue; sprintf(gName,"gEMaxPos_%i",i); gEMaxPos[i] = (TGraph*) ifile->Get(gName); if(gEMaxPos[i]==NULL) { gEMaxPos[i] = new TGraph(); gEMaxPos[i]->SetName(gName); } else { nPoints = gEMaxPos[i]->GetN(); } gEMaxPos[i]->Set(nPoints+1); if(opt.Contains("units") && n0) gEMaxPos[i]->SetPoint(nPoints, 1e3 * skindepth * Time,EMaxPos[i]); else gEMaxPos[i]->SetPoint(nPoints,Time,EMaxPos[i]); if(opt.Contains("units") && n0) { gEMaxPos[i]->GetYaxis()->SetTitle("#zeta_{min} [mm]"); gEMaxPos[i]->GetXaxis()->SetTitle("Z [mm]"); } else { gEMaxPos[i]->GetYaxis()->SetTitle("#zeta_{min} [c/#omega_{p}]"); gEMaxPos[i]->GetXaxis()->SetTitle("T [c/#omega_{p}]"); } gEMaxPos[i]->Write(gEMaxPos[i]->GetName(),TObject::kOverwrite); sprintf(gName,"gEMaxValue_%i",i); gEMaxValue[i] = (TGraph*) ifile->Get(gName); if(gEMaxValue[i]==NULL) { gEMaxValue[i] = new TGraph(); gEMaxValue[i]->SetName(gName); } else { nPoints = gEMaxValue[i]->GetN(); } gEMaxValue[i]->Set(nPoints+1); if(opt.Contains("units") && n0) gEMaxValue[i]->SetPoint(nPoints, 1e3 * skindepth * Time,EMaxValue[i]); else gEMaxValue[i]->SetPoint(nPoints,Time,EMaxValue[i]); if(opt.Contains("units") && n0) { gEMaxValue[i]->GetYaxis()->SetTitle("E_{min} [GV/m]"); gEMaxValue[i]->GetXaxis()->SetTitle("Z [mm]"); } else { gEMaxValue[i]->GetYaxis()->SetTitle("E_{min} [E_{0}]"); gEMaxValue[i]->GetXaxis()->SetTitle("T [c/#omega_{p}]"); } gEMaxValue[i]->Write(gEMaxValue[i]->GetName(),TObject::kOverwrite); } C->cd(2); gPad->SetGridy(1); gPad->SetGridx(0); gPad->SetFrameLineWidth(2); Float_t minPhase = 99.; Float_t maxPhase = -99.; Float_t minField = 99.; Float_t maxField = -99.; Double_t *yEMaxPos[Nfields]; Double_t *yEMaxValue[Nfields]; for(Int_t i=0;i<Nfields;i++) { yEMaxPos[i] = gEMaxPos[i]->GetY(); yEMaxValue[i] = gEMaxValue[i]->GetY(); for(Int_t j=0;j<gEMaxPos[0]->GetN();j++) { if(yEMaxPos[i][j]>maxPhase) maxPhase = yEMaxPos[i][j]; if(yEMaxPos[i][j]<minPhase) minPhase = yEMaxPos[i][j]; if(yEMaxValue[i][j]>maxField) maxField = yEMaxValue[i][j]; if(yEMaxValue[i][j]<minField) minField = yEMaxValue[i][j]; } } Float_t margin = (maxPhase - minPhase)/10; gEMaxPos[0]->GetYaxis()->SetRangeUser(minPhase-margin,maxPhase+margin); gEMaxPos[0]->GetYaxis()->CenterTitle(); gEMaxPos[0]->GetXaxis()->CenterTitle(); gEMaxPos[0]->SetLineColor(phaseC); gEMaxPos[0]->SetMarkerColor(phaseC); gEMaxPos[0]->SetLineWidth(3); gEMaxPos[0]->SetMarkerStyle(20); gEMaxPos[0]->SetMarkerSize(1.4); gEMaxPos[0]->Draw("APC"); if(Nfields>1) { gEMaxPos[1]->SetLineStyle(1); gEMaxPos[1]->SetLineColor(phaseC); gEMaxPos[1]->SetMarkerColor(phaseC); gEMaxPos[1]->SetLineWidth(1); gEMaxPos[1]->SetMarkerStyle(24); gEMaxPos[1]->SetMarkerSize(1.4); gEMaxPos[1]->Draw("PC"); } // Emax value // New axis first: C->Update(); // Needed for the axis! margin = (maxField - minField)/10; if (margin==0) margin = 1; Float_t rightmin = minField-margin; Float_t rightmax = maxField+margin; Float_t slope = (gPad->GetUymax() - gPad->GetUymin())/(rightmax-rightmin); TGaxis *axisEmax = new TGaxis(gPad->GetUxmax(),gPad->GetUymin(),gPad->GetUxmax(), gPad->GetUymax(),rightmin,rightmax,505,"+L"); axisEmax->SetLineWidth(1); axisEmax->SetLineColor(fieldC); axisEmax->SetLabelColor(fieldC); axisEmax->SetTitleColor(fieldC); if(opt.Contains("units") && n0) axisEmax->SetTitle("E_{min} [GV/m]"); else axisEmax->SetTitle("E_{min} [E_{0}]"); axisEmax->CenterTitle(); axisEmax->SetTitleSize(0.05); axisEmax->SetTitleOffset(1.2); axisEmax->SetLabelSize(0.05); axisEmax->SetLabelOffset(0.006); axisEmax->Draw(); // Adjust the TGraph Double_t *x = gEMaxValue[0]->GetX(); Double_t *y = gEMaxValue[0]->GetY(); for(Int_t i=0;i<gEMaxValue[0]->GetN();i++) { gEMaxValue[0]->SetPoint(i,x[i],(y[i]-rightmin)*slope + gPad->GetUymin()); } gEMaxValue[0]->SetLineColor(fieldC); gEMaxValue[0]->SetMarkerColor(fieldC); gEMaxValue[0]->SetLineWidth(3); gEMaxValue[0]->SetMarkerStyle(20); gEMaxValue[0]->SetMarkerSize(1.4); gEMaxValue[0]->Draw("PC"); if(Nfields>1) { x = gEMaxValue[1]->GetX(); y = gEMaxValue[1]->GetY(); for(Int_t i=0;i<gEMaxValue[1]->GetN();i++) { gEMaxValue[1]->SetPoint(i,x[i],(y[i]-rightmin)*slope + gPad->GetUymin()); } gEMaxValue[1]->SetLineColor(fieldC); gEMaxValue[1]->SetMarkerColor(fieldC); gEMaxValue[1]->SetLineWidth(1); gEMaxValue[1]->SetMarkerStyle(24); gEMaxValue[1]->SetMarkerSize(1.4); gEMaxValue[1]->Draw("PC"); } // Emax value // New axis first: C->Update(); // Needed for the axis! C->cd(); ifile->Close(); // Print to a file PlasmaGlob::imgconv(C,fOutName,opt); // --------------------------------------------------------- }