Changeset 8173 for trunk/MagicSoft
- Timestamp:
- 10/27/06 20:12:39 (18 years ago)
- Location:
- trunk/MagicSoft/Mars
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/Changelog
r8172 r8173 34 34 - added reading and usage of "CalcHadronness" when processing 35 35 the MCs 36 - added a plot for the Cut efficiency 36 37 37 38 -
trunk/MagicSoft/Mars/mjobs/MJSpectrum.cc
r8172 r8173 36 36 #include <TH1.h> 37 37 #include <TH2.h> 38 #include <TLine.h> 38 39 #include <TFile.h> 39 40 #include <TChain.h> … … 972 973 973 974 return kTRUE; 975 } 976 977 // -------------------------------------------------------------------------- 978 // 979 void MJSpectrum::DisplayCutEfficiency(const MHCollectionArea &area0, const MHCollectionArea &area1) const 980 { 981 if (!fDisplay) 982 return; 983 984 const TH1D &trig = area0.GetHEnergy(); 985 TH1D &cut = (TH1D&)*area1.GetHEnergy().Clone(); 986 987 fDisplay->AddTab("CutEff"); 988 989 gPad->SetBorderMode(0); 990 gPad->SetFrameBorderMode(0); 991 gPad->SetLogx(); 992 gPad->SetGridx(); 993 gPad->SetGridy(); 994 995 cut.Divide(&trig); 996 cut.Scale(100); 997 cut.SetNameTitle("CutEff", "Background Supression: Cut efficiency (after star)"); 998 cut.SetYTitle("\\eta [%]"); 999 cut.SetDirectory(0); 1000 cut.SetMinimum(0); 1001 cut.SetMaximum(100); 1002 cut.SetBit(kCanDelete); 1003 cut.Draw(); 1004 1005 TLine line; 1006 line.SetLineColor(kBlue); 1007 line.SetLineWidth(2); 1008 line.SetLineStyle(kDashed); 1009 line.DrawLine(cut.GetBinLowEdge(1), 50, cut.GetBinLowEdge(cut.GetNbinsX()+1), 50); 974 1010 } 975 1011 … … 1274 1310 cout << "MC normalization factor: " << scale << endl; 1275 1311 1312 // Display cut efficiency 1313 DisplayCutEfficiency(area0, area1); 1314 1276 1315 // Overlay normalized plots 1277 1316 DisplaySize(plist, scale); -
trunk/MagicSoft/Mars/mjobs/MJSpectrum.h
r8172 r8173 51 51 TArrayD DisplaySpectrum(MHCollectionArea &area, TH1D &excess, MHEnergyEst &hest, Double_t ontime) const; 52 52 Bool_t DisplaySize(MParList &plist, Double_t scale) const; 53 void DisplayCutEfficiency(const MHCollectionArea &area0, const MHCollectionArea &area1) const; 53 54 Bool_t PlotSame(MStatusArray &arr, MParList &plist, const char *name, const char *tab, const char *plot, Double_t scale) const; 54 55
Note:
See TracChangeset
for help on using the changeset viewer.