ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/OSUT3Analysis/AnaTools/plugins/OSUAnalysis.h
(Generate patch)

Comparing UserCode/OSUT3Analysis/AnaTools/plugins/OSUAnalysis.h (file contents):
Revision 1.1 by lantonel, Mon Jan 21 10:39:36 2013 UTC vs.
Revision 1.8 by lantonel, Wed Feb 13 10:05:48 2013 UTC

# Line 6 | Line 6
6   #include <string>
7   #include <vector>
8  
9 + #include "TH1.h"
10   #include "TH1D.h"
11   #include "TH2D.h"
12   #include "TLorentzVector.h"
# Line 51 | Line 52 | class OSUAnalysis : public edm::EDAnalyz
52  
53        void analyze (const edm::Event &, const edm::EventSetup &);
54        bool evaluateComparison (double, string, double);
55 +      bool evaluateTriggers   (vector<string>,const BNtriggerCollection*);
56 +      double applyFunction(string, double);
57  
58 <      double valueLookup (const BNjet*, string);
59 <      double valueLookup (const BNmuon*, string);
60 <      double valueLookup (const BNelectron*, string);
61 <      double valueLookup (const BNevent*, string);
62 <      double valueLookup (const BNtau*, string);
63 <      double valueLookup (const BNmet*, string);
64 <      double valueLookup (const BNtrack*, string);
65 <      double valueLookup (const BNgenjet*, string);
66 <      double valueLookup (const BNmcparticle*, string);
67 <      double valueLookup (const BNprimaryvertex*, string);
68 <      double valueLookup (const BNbxlumi*, string);
69 <      double valueLookup (const BNphoton*, string);
70 <      double valueLookup (const BNsupercluster*, string);
58 >      double valueLookup (const BNjet* object, string variable, string function = "");
59 >      double valueLookup (const BNmuon* object, string variable, string function = "");
60 >      double valueLookup (const BNelectron* object, string variable, string function = "");
61 >      double valueLookup (const BNevent* object, string variable, string function = "");
62 >      double valueLookup (const BNtau* object, string variable, string function = "");
63 >      double valueLookup (const BNmet* object, string variable, string function = "");
64 >      double valueLookup (const BNtrack* object, string variable, string function = "");
65 >      double valueLookup (const BNgenjet* object, string variable, string function = "");
66 >      double valueLookup (const BNmcparticle* object, string variable, string function = "");
67 >      double valueLookup (const BNprimaryvertex* object, string variable, string function = "");
68 >      double valueLookup (const BNbxlumi* object, string variable, string function = "");
69 >      double valueLookup (const BNphoton* object, string variable, string function = "");
70 >      double valueLookup (const BNsupercluster* object, string variable, string function = "");
71        //BNskimbits
69      //BNtrigger
72        //BNtrigobj
73  
74        vector<string> splitString (string);
# Line 101 | Line 103 | class OSUAnalysis : public edm::EDAnalyz
103        edm::InputTag bxlumis_;
104        edm::InputTag photons_;
105        edm::InputTag superclusters_;
106 +      edm::InputTag triggers_;
107  
108 +      BNprimaryvertex *primaryVertex_;
109  
110        vector<edm::ParameterSet> channels_;
111 +      vector<edm::ParameterSet> histogramSets_;
112 +
113 +      bool plotAllObjectsInPassingEvents;
114  
115        vector<map<string, TH1D*> > oneDHists_;
116 +      vector<map<string, TH2D*> > twoDHists_;
117  
118        edm::Service<TFileService> fs_;
119  
120        CutFlow *masterCutFlow_;
121        vector<CutFlow *> cutFlows_;
122  
123 +      typedef struct {
124 +        string name;
125 +        string title;
126 +        vector<double> bins;
127 +        string inputCollection;
128 +        vector<string> inputVariables;
129 +        string function;
130 +      } histogram;
131  
132        struct cut {
133          string inputCollection;
134          string variable;
135          string comparativeOperator;
136 +        string function;
137          double cutValue;
138          int    numberRequired;
139          string eventComparativeOperator;
# Line 125 | Line 142 | class OSUAnalysis : public edm::EDAnalyz
142  
143        struct channel {
144          string name;
145 +        vector<string> triggers;
146          vector<cut> cuts;
129        vector<string> inputCollections;
147        };
148  
149 +      vector<string>  objectsToPlot;
150        vector<string>  allNecessaryObjects;
151        vector<channel> channels;
152 +      vector<histogram> histograms;
153  
154        template <class InputCollection> void setObjectFlags(cut &, uint, flagMap &, flagMap &, InputCollection, string);
155 +      template <class InputCollection>  void fillHistogram(TH1*, histogram, InputCollection, vector<bool>);
156  
157  
158  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines