ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitHzz4l/Selection/src/MuonSelection.cc
(Generate patch)

Comparing UserCode/MitHzz4l/Selection/src/MuonSelection.cc (file contents):
Revision 1.3 by khahn, Sat Oct 1 13:00:23 2011 UTC vs.
Revision 1.4 by khahn, Mon Oct 17 16:23:43 2011 UTC

# Line 1 | Line 1
1   #include <math.h>
2   #include "HiggsAnaDefs.hh"
3 #include "TMuon.hh"
3   #include "MuonSelection.h"
4  
5   unsigned passSoftMuonSelection( const mithep::TMuon * mu ) {
# Line 74 | Line 73 | unsigned passMuonSelectionZZ( const mith
73    return failmask;
74  
75   };
76 +
77 +
78 + //
79 + // Kevin's WW selection
80 + //
81 + unsigned passMuonSelection( const mithep::TMuon * mu ) {
82 +  int level=0;
83 +  unsigned failmask=0x0;
84 +
85 +  if(mu->pt < 5) {
86 +    failmask |= (1<<level);
87 +  }
88 +
89 +  level++;
90 +  if(fabs(mu->eta) > 2.4) {
91 +    failmask |= (1<<level);
92 +  }
93 +
94 +  level++;
95 +  if(!(mu->typeBits & kGlobal)) {
96 +    failmask |= (1<<level);
97 +  }
98 +
99 +  level++;
100 +  if(mu->nTkHits          < 11) {
101 +    failmask |= (1<<level);
102 +  }
103 +
104 +  level++;
105 +  if(mu->nPixHits         < 1) {
106 +    failmask |= (1<<level);
107 +  }
108 +
109 +  level++;
110 +  if(mu->ptErr/mu->pt > 0.1)   {
111 +    failmask |= (1<<level);
112 +  }
113 +
114 +  level++;
115 +  if( fabs(mu->dz) > 0.1 )   {
116 +    failmask |= (1<<level);
117 +  }
118 +
119 +
120 +  Bool_t isGlobal  = (mu->typeBits & kGlobal) && (mu->muNchi2 < 10) && (mu->nMatch > 1) && (mu->nValidHits > 0);
121 +  Bool_t isTracker = (mu->typeBits & kTracker) && (mu->qualityBits & kTMLastStationTight);
122 +  
123 +  level++;
124 +  if(!isGlobal && !isTracker) {
125 +    failmask |= (1<<level);
126 +  }
127 +
128 +  level++;
129 +  if(fabs(mu->d0)>0.02)   {
130 +    failmask |= (1<<level);
131 +  }
132 +  /*
133 +  if(mu->pt>20) {
134 +    if(fabs(mu->d0)>0.02)   {
135 +      failmask |= (1<<level);
136 +    }
137 +  } else {
138 +    if(fabs(mu->d0)>0.01)  {
139 +    failmask |= (1<<level);
140 +    }
141 +  }
142 +  */
143 +  return failmask;
144 +
145 + };

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines